类 InventoryOpenEvent
java.lang.Object
org.bukkit.event.Event
org.bukkit.event.inventory.InventoryEvent
org.bukkit.event.inventory.InventoryOpenEvent
- 所有已实现的接口:
Cancellable
当玩家打开物品栏时触发本事件
-
嵌套类概要
从类继承的嵌套类/接口 org.bukkit.event.Event
Event.Result
-
字段概要
从类继承的字段 org.bukkit.event.inventory.InventoryEvent
transaction
-
构造器概要
-
方法概要
修饰符和类型方法说明static @NotNull HandlerList
final @NotNull HumanEntity
返回涉及此事件的玩家.boolean
获取此事件的取消状态.void
setCancelled
(boolean cancel) 设置此事件的取消状态.从类继承的方法 org.bukkit.event.inventory.InventoryEvent
getInventory, getView, getViewers
从类继承的方法 org.bukkit.event.Event
getEventName, isAsynchronous
-
构造器详细资料
-
InventoryOpenEvent
-
-
方法详细资料
-
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
- 覆盖:
getHandlers
在类中InventoryEvent
-
getHandlerList
-