Interface AnnouncementTask


public interface AnnouncementTask
The AnnouncementTask interface represents a task for announcing messages to players in an arena. It provides methods to load and add messages for players, retrieve the associated arena, Bukkit task, task ID, and cancel the task.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addMessageForPlayer(org.bukkit.entity.Player p, String message)
    Add a message for a specific player.
    void
    addMessagesForPlayer(org.bukkit.entity.Player p, List<String> messages)
    Add a list of messages for a specific player.
    void
    Cancel the announcement task.
    Get the arena associated with this announcement task.
    org.bukkit.scheduler.BukkitTask
    Get the Bukkit task associated with this announcement task.
    int
    Get the task ID of the Bukkit task.
    void
    loadMessagesForPlayer(org.bukkit.entity.Player p, String path)
    Load messages for a specific player from a given message path.
  • Method Details

    • getArena

      IArena getArena()
      Get the arena associated with this announcement task.
      Returns:
      The arena associated with the task.
    • getBukkitTask

      org.bukkit.scheduler.BukkitTask getBukkitTask()
      Get the Bukkit task associated with this announcement task.
      Returns:
      The Bukkit task associated with the task.
    • getTask

      int getTask()
      Get the task ID of the Bukkit task.
      Returns:
      The task ID of the Bukkit task.
    • cancel

      void cancel()
      Cancel the announcement task.
    • loadMessagesForPlayer

      void loadMessagesForPlayer(org.bukkit.entity.Player p, String path)
      Load messages for a specific player from a given message path.
      Parameters:
      p - The player to load the messages for.
      path - The message path to load the messages from.
    • addMessageForPlayer

      void addMessageForPlayer(org.bukkit.entity.Player p, String message)
      Add a message for a specific player.
      Parameters:
      p - The player to add the message for.
      message - The message to add.
    • addMessagesForPlayer

      void addMessagesForPlayer(org.bukkit.entity.Player p, List<String> messages)
      Add a list of messages for a specific player.
      Parameters:
      p - The player to add the messages for.
      messages - The list of messages to add.