Class PlayerCustomClickEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.player.PlayerEvent
org.bukkit.event.player.PlayerCustomClickEvent

@Experimental public class PlayerCustomClickEvent extends PlayerEvent
Called after a player runs a custom action from a chat event or form submission.
  • Constructor Details

    • PlayerCustomClickEvent

      public PlayerCustomClickEvent(@NotNull Player player, @NotNull NamespacedKey id, @Nullable com.google.gson.JsonElement data)
  • Method Details

    • getId

      @NotNull public NamespacedKey getId()
      Gets the ID of the custom action.
      Returns:
      custom action ID
    • getData

      @Nullable public com.google.gson.JsonElement getData()
      Gets the data of the custom action as a JsonElement, or null if not available.
      If not a form submission, then may be null.
      Returns:
      data as JSON or null
    • getHandlers

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

      @NotNull public static HandlerList getHandlerList()