类 InventoryOpenEvent

所有已实现的接口:
Cancellable

public class InventoryOpenEvent extends InventoryEvent implements Cancellable
当玩家打开物品栏时触发本事件
  • 构造器详细资料

  • 方法详细资料

    • getPlayer

      @NotNull public final @NotNull HumanEntity getPlayer()
      返回涉及此事件的玩家.

      原文:Returns the player involved in this event

      返回:
      涉及此事件的玩家
    • isCancelled

      public boolean isCancelled()
      获取此事件的取消状态. 一个取消的事件将不会在服务器上执行,但将仍然传递给其他插件.

      如果一个物品栏打开事件被取消,物品栏界面将不会显示.

      原文:Gets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.

      If an inventory open event is cancelled, the inventory screen will not show.

      指定者:
      isCancelled 在接口中 Cancellable
      返回:
      事件取消状态
    • setCancelled

      public void setCancelled(boolean cancel)
      设置此事件的取消状态. 一个取消的事件将不会在服务器上执行,但将仍然传递给其他插件.

      如果一个物品栏打开事件被取消,物品栏界面将不会显示.

      原文:Sets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.

      If an inventory open event is cancelled, the inventory screen will not show.

      指定者:
      setCancelled 在接口中 Cancellable
      参数:
      cancel - 事件取消状态
    • getHandlers

      @NotNull public @NotNull HandlerList getHandlers()
      覆盖:
      getHandlers 在类中 InventoryEvent
    • getHandlerList

      @NotNull public static @NotNull HandlerList getHandlerList()