Class ActionBar


  • public class ActionBar
    extends MessageDisplay
    A Utilities class to create an actionbar
    • Constructor Detail

      • ActionBar

        public ActionBar​(java.lang.String text)
        Create an actionbar
        Parameters:
        text - The Text
      • ActionBar

        public ActionBar​(java.lang.String text,
                         int time)
        Create an actionbar
        Parameters:
        text - The Text
        time - The Time
      • ActionBar

        public ActionBar​(java.lang.String text,
                         TimedEvent timedEvent)
        Create an actionbar
        Parameters:
        text - The Text
        timedEvent - The TimedEvent
      • ActionBar

        public ActionBar​(java.lang.String text,
                         TimedEvent timedEvent,
                         boolean autoStartTimedEvent)
        Create an actionbar
        Parameters:
        text - The Text
        timedEvent - The TimedEvent
        autoStartTimedEvent - If the TimedEvent autostarts
      • ActionBar

        public ActionBar​(java.lang.String text,
                         int time,
                         TimedEvent timedEvent)
        Create an actionbar
        Parameters:
        text - The text
        time - The time
        timedEvent - If the TimedEvent Autostarts
      • ActionBar

        public ActionBar​(java.lang.String text,
                         int time,
                         TimedEvent timedEvent,
                         boolean autoStartTimedEvent)
        Create an actionbar
        Parameters:
        text - The Text
        time - The time
        timedEvent - The TimedEvent
        autoStartTimedEvent - If the TimedEvent autostarts
    • Method Detail

      • clear

        public static void clear​(org.bukkit.entity.Player player)
        Clear the player's title
        Parameters:
        player - The Player
      • getPlayingActionBar

        public static ActionBar getPlayingActionBar​(org.bukkit.entity.Player player)
        Parameters:
        player - The player
        Returns:
        Get the actionbar that is being played for the player
      • getText

        public java.lang.String getText()
        Specified by:
        getText in class MessageDisplay
        Returns:
        Get the text
      • setText

        public void setText​(java.lang.String text)
        Set the text
        Specified by:
        setText in class MessageDisplay
        Parameters:
        text - The text to set
      • setTimedEvent

        public void setTimedEvent​(TimedEvent timedEvent)
        Set the TimedEvent
        Overrides:
        setTimedEvent in class TimedObject
        Parameters:
        timedEvent - The TimedEvent
      • stop

        public void stop​(org.bukkit.entity.Player player)
        Stop showing the actionbar
        Specified by:
        stop in class MessageDisplay
        Parameters:
        player - The player
      • send

        public void send​(org.bukkit.entity.Player player)
        Send the player an title
        Specified by:
        send in class MessageDisplay
        Parameters:
        player - The Player