Interface Message


public interface Message
The message class used for processing messages from the config and sending them as chat or title messages.
  • Method Summary

    Modifier and Type
    Method
    Description
    colors(boolean parse)
    Set whether colors codes should be parsed when sending this message.
    placeholderOwner(org.bukkit.entity.Player owner)
    Set the player for whom the placeholders should be parsed.
    placeholders(boolean parse)
    Set whether placeholders should be parsed.
    replace(String search, String replace)
    Replace a part of the message with something else.
    void
    send(org.bukkit.command.CommandSender... senders)
    Send this message in the chat.
    void
    sendTitle(int in, int stay, int out, org.bukkit.entity.Player... players)
    Send this message as a title.
    void
    sendTitle(org.bukkit.entity.Player... players)
    Send this message as a title.
  • Method Details

    • colors

      Message colors(boolean parse)
      Set whether colors codes should be parsed when sending this message.
      Parameters:
      parse - Whether color codes should be parsed.
      Returns:
      The current Message.
    • replace

      Message replace(String search, String replace)
      Replace a part of the message with something else.
      Parameters:
      search - String to search for.
      replace - String to replace it with.
      Returns:
      The current Message.
    • send

      void send(org.bukkit.command.CommandSender... senders)
      Send this message in the chat.
      Parameters:
      senders - List of command senders to send the message to.
    • sendTitle

      void sendTitle(org.bukkit.entity.Player... players)
      Send this message as a title.
      Parameters:
      players - A list of players to send the title to.
    • placeholders

      Message placeholders(boolean parse)
      Set whether placeholders should be parsed.
      Parameters:
      parse - Whether placeholders should be parsed.
      Returns:
      Current Message.
    • placeholderOwner

      Message placeholderOwner(org.bukkit.entity.Player owner)
      Set the player for whom the placeholders should be parsed. Set this to null to keep the players you're sending the message to.
      Parameters:
      owner - The player for whom the placeholders should be parsed.
      Returns:
      Current Message.
    • sendTitle

      void sendTitle(int in, int stay, int out, org.bukkit.entity.Player... players)
      Send this message as a title.
      Parameters:
      in - The fade-in time in ticks.
      stay - The stay time in ticks.
      out - The fade-out time in ticks.
      players - A list of players to send the title to.