Class ChunkNotificationEvent

java.lang.Object
org.bukkit.event.Event
com.palmergames.bukkit.towny.event.ChunkNotificationEvent
All Implemented Interfaces:
org.bukkit.event.Cancellable

public class ChunkNotificationEvent extends org.bukkit.event.Event implements org.bukkit.event.Cancellable
  • Constructor Details

    • ChunkNotificationEvent

      public ChunkNotificationEvent(org.bukkit.entity.Player player, String message, WorldCoord toCoord, WorldCoord fromCoord)
      A cancellable event that lets other plugins change or disable a ChunkNotification shown to a player when they move between plots.
      Parameters:
      player - Player moving between townblocks/plots/chunks.
      message - Message Towny will show as a Chunk Notification.
      toCoord - WorldCoord they are moving into.
      fromCoord - WorldCoord they have left.
      Since:
      0.98.3.2
  • Method Details

    • getHandlers

      public org.bukkit.event.HandlerList getHandlers()
      Specified by:
      getHandlers in class org.bukkit.event.Event
    • getHandlerList

      public static org.bukkit.event.HandlerList getHandlerList()
    • isCancelled

      public boolean isCancelled()
      Specified by:
      isCancelled in interface org.bukkit.event.Cancellable
    • setCancelled

      public void setCancelled(boolean cancelled)
      Specified by:
      setCancelled in interface org.bukkit.event.Cancellable
    • getPlayer

      public org.bukkit.entity.Player getPlayer()
      Returns:
      Player which will be shown a Chunk Notification.
    • getMessage

      public String getMessage()
      Returns:
      The message the player will see.
    • setMessage

      public void setMessage(String message)
      Parameters:
      message - The ChunkNotification message that will be shown to the player.
    • getToCoord

      public WorldCoord getToCoord()
      Returns:
      The WorldCoord that the player has moved into.
    • getFromCoord

      public WorldCoord getFromCoord()
      Returns:
      The WorldCoord that the player has left.