程序包 org.bukkit.event.player

# 类 PlayerArmorStandManipulateEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.player.PlayerEvent
org.bukkit.event.player.PlayerInteractEntityEvent
org.bukkit.event.player.PlayerArmorStandManipulateEvent

所有已实现的接口:
  `Cancellable`

public class PlayerArmorStandManipulateEvent extends PlayerInteractEntityEvent
当玩家与装甲架交互并且进行交换, 取回或放置物品时触发本事件.

原文: Called when a player interacts with an armor stand and will either swap, retrieve or place an item.

- ## 嵌套类概要

  ## 从类继承的嵌套类/接口 org.bukkit.event.Event

  `Event.Result`

- ## 字段概要

  ### 从类继承的字段 org.bukkit.event.player.PlayerInteractEntityEvent

  `clickedEntity`

  ### 从类继承的字段 org.bukkit.event.player.PlayerEvent

  `player`

- ## 构造器概要

  构造器
  构造器
  说明
  `PlayerArmorStandManipulateEvent(@NotNull Player who, @NotNull ArmorStand clickedEntity, @NotNull ItemStack playerItem, @NotNull ItemStack armorStandItem, @NotNull EquipmentSlot slot)`
  已过时。
  `PlayerArmorStandManipulateEvent(@NotNull Player who, @NotNull ArmorStand clickedEntity, @NotNull ItemStack playerItem, @NotNull ItemStack armorStandItem, @NotNull EquipmentSlot slot, @NotNull EquipmentSlot hand)`

- ## 方法概要

  修饰符和类型
  方法
  说明
  `@NotNull ItemStack`
  `getArmorStandItem()`
  返回盔甲架的物品.
  `@NotNull EquipmentSlot`
  `getHand()`
  用于执行这次交互的手.
  `static @NotNull HandlerList`
  `getHandlerList()`
  `@NotNull HandlerList`
  `getHandlers()`
  `@NotNull ItemStack`
  `getPlayerItem()`
  返回玩家手持的物品.
  `@NotNull ArmorStand`
  `getRightClicked()`
  获取被玩家点击的实体.
  `@NotNull EquipmentSlot`
  `getSlot()`
  返回在此事件中盔甲架的装备槽.

  ### 从类继承的方法 org.bukkit.event.player.PlayerInteractEntityEvent

  `isCancelled, setCancelled`

  ### 从类继承的方法 org.bukkit.event.player.PlayerEvent

  `getPlayer`

  ### 从类继承的方法 org.bukkit.event.Event

  `getEventName, isAsynchronous`

  ### 从类继承的方法 java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## 构造器详细资料

  - ### PlayerArmorStandManipulateEvent

    public PlayerArmorStandManipulateEvent(@NotNull @NotNull Player who, @NotNull @NotNull ArmorStand clickedEntity, @NotNull @NotNull ItemStack playerItem, @NotNull @NotNull ItemStack armorStandItem, @NotNull @NotNull EquipmentSlot slot, @NotNull @NotNull EquipmentSlot hand)

  - ### PlayerArmorStandManipulateEvent

    @Deprecated public PlayerArmorStandManipulateEvent(@NotNull @NotNull Player who, @NotNull @NotNull ArmorStand clickedEntity, @NotNull @NotNull ItemStack playerItem, @NotNull @NotNull ItemStack armorStandItem, @NotNull @NotNull EquipmentSlot slot)
    已过时。

- ## 方法详细资料

  - ### getPlayerItem

    @NotNull public @NotNull ItemStack getPlayerItem()
    返回玩家手持的物品.
    - 如果玩家手持的物品为空时, 并且盔甲架的物品也为空时, 那么则玩家和盔甲架之间将不会有物品交换.
    - 如果玩家手持的物品为空时，但是盔甲架的物品不为空时，那么玩家将获得盔甲架的物品.
    - 如果玩家手持的物品不为空时，但盔甲架的物品为空时，则玩家物品将被放在盔甲架上.
    - 如果玩家手持的物品不为空时，盔甲架的物品也不为空时，则玩家物品将和盔甲架的物品将进行交换.
    - 如果该事件被取消, 那么交换将不会进行, 即物品不会进行交换.

    原文: Returns the item held by the player.

    If this item is empty and the armor stand item is also empty, there will be no transaction between the player and the armor stand. If the player's item is empty but the armor stand item is not, the player's item will be placed on the armor stand. If both items are not empty, the items will be swapped.

    In the case that this event is cancelled, the original items will remain the same.

    返回:
      the item held by the player.

  - ### getArmorStandItem

    @NotNull public @NotNull ItemStack getArmorStandItem()
    返回盔甲架的物品.
    - 如果玩家手持的物品为空时, 并且盔甲架的物品也为空时, 那么则玩家和盔甲架之间将不会有物品交换.
    - 如果玩家手持的物品为空时，但是盔甲架的物品不为空时，那么玩家将获得盔甲架的物品.
    - 如果玩家手持的物品不为空时，但盔甲架的物品为空时，则玩家物品将被放在盔甲架上.
    - 如果玩家手持的物品不为空时，盔甲架的物品也不为空时，则玩家物品将和盔甲架的物品将进行交换.
    - 如果该事件被取消, 那么交换将不会进行, 即物品不会进行交换.

    原文: Returns the item held by the armor stand.

    If this item is empty and the player's item is also empty, there will be no transaction between the player and the armor stand. If the player's item is empty but the armor stand item is not, then the player will obtain the armor stand item. In the case that the player's item is not empty but the armor stand item is empty, the player's item will be placed on the armor stand. If both items are not empty, the items will be swapped.

    In the case that the event is cancelled the original items will remain the same.

    返回:
      盔甲架的的物品 `ItemStack`

  - ### getSlot

    @NotNull public @NotNull EquipmentSlot getSlot()
    返回在此事件中盔甲架的装备槽.

    原文: Returns the raw item slot of the armor stand in this event.

    返回:
      获得或放置盔甲架的物品的下标. `EquipmentSlot`

  - ### getHand

    @NotNull public @NotNull EquipmentSlot getHand()
    用于执行这次交互的手.

    原文:The hand used to perform this interaction.

    Note that this is not the hand of the armor stand that was changed, but rather the hand used by the player to swap items with the armor stand.

    覆盖:
      `getHand` 在类中 `PlayerInteractEntityEvent`
    返回:
      用来交互的手

  - ### getRightClicked

    @NotNull public @NotNull ArmorStand getRightClicked()
    从类复制的说明: `PlayerInteractEntityEvent`
    获取被玩家点击的实体.

    原文:Gets the entity that was rightclicked by the player.

    覆盖:
      `getRightClicked` 在类中 `PlayerInteractEntityEvent`
    返回:
      被玩家点击的实体

  - ### getHandlers

    @NotNull public @NotNull HandlerList getHandlers()
    覆盖:
      `getHandlers` 在类中 `PlayerInteractEntityEvent`

  - ### getHandlerList

    @NotNull public static @NotNull HandlerList getHandlerList()