Class ToastNotification

java.lang.Object
eu.endercentral.crazy_advancements.advancement.ToastNotification

public class ToastNotification extends Object
Represents a Toast Notification
Author:
Axel
  • Field Details

    • NOTIFICATION_NAME

      public static final NameKey NOTIFICATION_NAME
    • NOTIFICATION_CRITERIA

      public static final Criteria NOTIFICATION_CRITERIA
    • NOTIFICATION_PROGRESS

      public static final AdvancementProgress NOTIFICATION_PROGRESS
  • Constructor Details

    • ToastNotification

      public ToastNotification(ItemStack icon, JSONMessage message, AdvancementDisplay.AdvancementFrame frame)
      Constructor for creating Toast Notifications
      Parameters:
      icon - The displayed Icon
      message - The displayed Message
      frame - Determines the displayed Title and Sound Effect (evaluated client-side and modifiable via resource packs)
    • ToastNotification

      public ToastNotification(ItemStack icon, String message, AdvancementDisplay.AdvancementFrame frame)
      Constructor for creating Toast Notifications
      Parameters:
      icon - The displayed Icon
      message - The displayed Message
      frame - Determines the displayed Title and Sound Effect (evaluated client-side and modifiable via resource packs)
    • ToastNotification

      public ToastNotification(Material icon, JSONMessage message, AdvancementDisplay.AdvancementFrame frame)
      Constructor for creating Toast Notifications
      Parameters:
      icon - The displayed Icon
      message - The displayed Message
      frame - Determines the displayed Title and Sound Effect (evaluated client-side and modifiable via resource packs)
    • ToastNotification

      public ToastNotification(Material icon, String message, AdvancementDisplay.AdvancementFrame frame)
      Constructor for creating Toast Notifications
      Parameters:
      icon - The displayed Icon
      message - The displayed Message
      frame - Determines the displayed Title and Sound Effect (evaluated client-side and modifiable via resource packs)
  • Method Details

    • getIcon

      public ItemStack getIcon()
      Gets the Icon
      Returns:
      The Icon
    • getMessage

      public JSONMessage getMessage()
      Gets the TItle
      Returns:
      The Title
    • getFrame

      Gets the Frame
      Returns:
      The Frame
    • send

      public void send(Player player)
      Sends this Toast Notification to a Player
      Parameters:
      player - The target Player