Class PlayerUseSpecialItemCommandEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.player.PlayerEvent
me.metallicgoat.specialItems.api.event.PlayerUseSpecialItemCommandEvent
All Implemented Interfaces:
ArenaEvent

public class PlayerUseSpecialItemCommandEvent extends PlayerEvent implements ArenaEvent
Gets called when a player is about to use the ExtraSpecialItemType.COMMAND special item.

It is not possible to cancel this event. Listen to PlayerUseSpecialItemEvent instead.

  • Constructor Details

  • Method Details

    • getArena

      public Arena getArena()
      Specified by:
      getArena in interface ArenaEvent
    • getCommand

      public String getCommand()
      Gets the unformatted command to be executed.
      Returns:
      The unformatted command
    • setCommand

      public void setCommand(String command)
      Sets the unformatted command to be executed.
      Parameters:
      command - The new unformatted command
    • isAsConsole

      public boolean isAsConsole()
      Gets whether the command will be executed as console.
      Returns:
      true if executed as console, false if executed as player
    • setAsConsole

      public void setAsConsole(boolean asConsole)
      Sets whether the command will be executed as console.
      Parameters:
      asConsole - true to execute as console, false to execute as player
    • getHandlers

      public HandlerList getHandlers()
      Specified by:
      getHandlers in class Event
    • getHandlerList

      public static HandlerList getHandlerList()