枚举的使用
org.bukkit.inventory.EquipmentSlot
使用EquipmentSlot的程序包
程序包
说明
Bukkit API的顶级程序包, 包含通用的API类和接口.
与属性有关的类 (Minecraft Wiki - 属性).
与怪物生成器有关的类。
为在
世界内存在的非三维像素单位(实体)提供的接口,包含玩家、怪物、抛射物等.参与操作玩家物品栏和物品交互的类.
用于操作可以存储在
物品堆的额外数据的接口.Isolated components which may form part of item meta.
-
org.bukkit中EquipmentSlot的使用
返回EquipmentSlot的org.bukkit中的方法参数类型为EquipmentSlot的org.bukkit中的方法修饰符和类型方法说明Material.getDefaultAttributeModifiers(@NotNull EquipmentSlot slot) UnsafeValues.getDefaultAttributeModifiers(Material material, EquipmentSlot slot) 已过时, 待删除: 此 API 元素将从以后的版本中删除。 -
org.bukkit.attribute中EquipmentSlot的使用
参数类型为EquipmentSlot的org.bukkit.attribute中的构造器限定符构造器说明AttributeModifier(@NotNull UUID uuid, @NotNull String name, double amount, @NotNull AttributeModifier.Operation operation, @Nullable EquipmentSlot slot) 已过时, 待删除: 此 API 元素将从以后的版本中删除。 -
org.bukkit.block.spawner中EquipmentSlot的使用
返回变量类型为EquipmentSlot的类型的org.bukkit.block.spawner中的方法类型变量类型为EquipmentSlot的org.bukkit.block.spawner中的构造器参数 -
org.bukkit.entity中EquipmentSlot的使用
参数类型为EquipmentSlot的org.bukkit.entity中的方法修饰符和类型方法说明voidArmorStand.addEquipmentLock(@NotNull EquipmentSlot slot, @NotNull ArmorStand.LockType lockType) 使用指定的锁定机制锁定装备槽位.booleanArmorStand.hasEquipmentLock(@NotNull EquipmentSlot slot, @NotNull ArmorStand.LockType lockType) 返回此盔甲架是否具有指定的锁定机制.voidArmorStand.removeEquipmentLock(@NotNull EquipmentSlot slot, @NotNull ArmorStand.LockType lockType) 移除锁定机制.voidPlayer.sendEquipmentChange(@NotNull LivingEntity entity, @NotNull EquipmentSlot slot, @Nullable ItemStack item) 向玩家发送某个实体的盔甲槽变化数据包.类型变量类型为EquipmentSlot的org.bukkit.entity中的方法参数修饰符和类型方法说明voidPlayer.sendEquipmentChange(@NotNull LivingEntity entity, @NotNull Map<EquipmentSlot, ItemStack> items) 发送目标实体的多个装备槽变更数据包. -
org.bukkit.event.block中EquipmentSlot的使用
参数类型为EquipmentSlot的org.bukkit.event.block中的构造器限定符构造器说明BlockPlaceEvent(@NotNull Block placedBlock, @NotNull BlockState replacedBlockState, @NotNull Block placedAgainst, @NotNull ItemStack itemInHand, @NotNull Player thePlayer, boolean canBuild, @NotNull EquipmentSlot hand) -
org.bukkit.event.entity中EquipmentSlot的使用
修饰符和类型方法说明EntityPlaceEvent.getHand()返回放置实体时使用的手.EntityResurrectEvent.getHand()获取发现不死图腾的手, 如果实体没有不死图腾则返回null.EntityShootBowEvent.getHand()获取射出弓的手。PlayerLeashEntityEvent.getHand()返回玩家用于拴绳实体的手。参数类型为EquipmentSlot的org.bukkit.event.entity中的构造器限定符构造器说明EntityPlaceEvent(@NotNull Entity entity, @Nullable Player player, @NotNull Block block, @NotNull BlockFace blockFace, @NotNull EquipmentSlot hand) EntityResurrectEvent(@NotNull LivingEntity what, @Nullable EquipmentSlot hand) EntityShootBowEvent(@NotNull LivingEntity shooter, @Nullable ItemStack bow, @Nullable ItemStack consumable, @NotNull Entity projectile, @NotNull EquipmentSlot hand, float force, boolean consumeItem) PlayerLeashEntityEvent(@NotNull Entity what, @NotNull Entity leashHolder, @NotNull Player leasher, @NotNull EquipmentSlot hand) -
org.bukkit.event.hanging中EquipmentSlot的使用
参数类型为EquipmentSlot的org.bukkit.event.hanging中的构造器限定符构造器说明HangingPlaceEvent(@NotNull Hanging hanging, @Nullable Player player, @NotNull Block block, @NotNull BlockFace blockFace, @Nullable EquipmentSlot hand) 已过时。HangingPlaceEvent(@NotNull Hanging hanging, @Nullable Player player, @NotNull Block block, @NotNull BlockFace blockFace, @Nullable EquipmentSlot hand, @Nullable ItemStack itemStack) -
org.bukkit.event.player中EquipmentSlot的使用
修饰符和类型方法说明PlayerArmorStandManipulateEvent.getHand()用于执行这次交互的手.PlayerBucketEntityEvent.getHand()获取用于捕获实体的手.PlayerBucketEvent.getHand()获取在此事件中使用的手.PlayerFishEvent.getHand()获取此事件中使用的手.PlayerHarvestBlockEvent.getHand()获取用于收获方块的手。PlayerInteractEntityEvent.getHand()用于执行这次交互的手.PlayerInteractEvent.getHand()获取用来进行本次交互的手, 但当玩家的交互动作类型为Action.PHYSICAL时可能为空.PlayerItemConsumeEvent.getHand()获取用于消耗物品的手.PlayerShearEntityEvent.getHand()获取用于剪切实体的手.PlayerUnleashEntityEvent.getHand()获取玩家用来解开拴绳的手.PlayerArmorStandManipulateEvent.getSlot()返回在此事件中盔甲架的装备槽.PlayerItemMendEvent.getSlot()获取被修复的ItemStack所在的EquipmentSlot.参数类型为EquipmentSlot的org.bukkit.event.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) PlayerBucketEmptyEvent(@NotNull Player who, @NotNull Block block, @NotNull Block blockClicked, @NotNull BlockFace blockFace, @NotNull Material bucket, @NotNull ItemStack itemInHand, @NotNull EquipmentSlot hand) PlayerBucketEntityEvent(@NotNull Player player, @NotNull Entity entity, @NotNull ItemStack originalBucket, @NotNull ItemStack entityBucket, @NotNull EquipmentSlot hand) PlayerBucketEvent(@NotNull Player who, @NotNull Block block, @NotNull Block blockClicked, @NotNull BlockFace blockFace, @NotNull Material bucket, @NotNull ItemStack itemInHand, @NotNull EquipmentSlot hand) PlayerBucketFillEvent(@NotNull Player who, @NotNull Block block, @NotNull Block blockClicked, @NotNull BlockFace blockFace, @NotNull Material bucket, @NotNull ItemStack itemInHand, @NotNull EquipmentSlot hand) PlayerBucketFishEvent(@NotNull Player player, @NotNull Fish fish, @NotNull ItemStack waterBucket, @NotNull ItemStack fishBucket, @NotNull EquipmentSlot hand) 已过时。PlayerFishEvent(@NotNull Player player, @Nullable Entity entity, @NotNull FishHook hookEntity, @Nullable EquipmentSlot hand, @NotNull PlayerFishEvent.State state) PlayerHarvestBlockEvent(@NotNull Player player, @NotNull Block harvestedBlock, @NotNull EquipmentSlot hand, @NotNull List<ItemStack> itemsHarvested) PlayerInteractAtEntityEvent(@NotNull Player who, @NotNull Entity clickedEntity, @NotNull Vector position, @NotNull EquipmentSlot hand) PlayerInteractEntityEvent(@NotNull Player who, @NotNull Entity clickedEntity, @NotNull EquipmentSlot hand) PlayerInteractEvent(@NotNull Player who, @NotNull Action action, @Nullable ItemStack item, @Nullable Block clickedBlock, @NotNull BlockFace clickedFace, @Nullable EquipmentSlot hand) PlayerInteractEvent(@NotNull Player who, @NotNull Action action, @Nullable ItemStack item, @Nullable Block clickedBlock, @NotNull BlockFace clickedFace, @Nullable EquipmentSlot hand, @Nullable Vector clickedPosition) PlayerItemConsumeEvent(@NotNull Player player, @NotNull ItemStack item, @NotNull EquipmentSlot hand) PlayerItemMendEvent(@NotNull Player who, @NotNull ItemStack item, @NotNull EquipmentSlot slot, @NotNull ExperienceOrb experienceOrb, int repairAmount) PlayerShearEntityEvent(@NotNull Player who, @NotNull Entity what, @NotNull ItemStack item, @NotNull EquipmentSlot hand) PlayerUnleashEntityEvent(@NotNull Entity entity, @NotNull Player player, @NotNull EquipmentSlot hand) -
org.bukkit.inventory中EquipmentSlot的使用
修饰符和类型方法说明EquipmentSlotGroup.getExample()已过时。仅用于内部兼容性static EquipmentSlot返回带有指定名称的该类型的枚举常量。static EquipmentSlot[]EquipmentSlot.values()按照声明该枚举类型的常量的顺序, 返回一个包含这些常量的数组。参数类型为EquipmentSlot的org.bukkit.inventory中的方法修饰符和类型方法说明ItemType.getDefaultAttributeModifiers(@NotNull EquipmentSlot slot) EntityEquipment.getItem(@NotNull EquipmentSlot slot) 获取物品栏中指定装备槽位的 ItemStack.PlayerInventory.getItem(@NotNull EquipmentSlot slot) 获取指定装备槽位中的物品栈.voidEntityEquipment.setItem(@NotNull EquipmentSlot slot, @Nullable ItemStack item) 将给定的 ItemStack 存储到物品栏中指定的装备槽位.voidEntityEquipment.setItem(@NotNull EquipmentSlot slot, @Nullable ItemStack item, boolean silent) 将给定的 ItemStack 存储到物品栏中指定的装备槽位.voidPlayerInventory.setItem(@NotNull EquipmentSlot slot, @Nullable ItemStack item) 将给定的物品栈设置到指定的装备槽位中.booleanEquipmentSlotGroup.test(@NotNull EquipmentSlot test) -
org.bukkit.inventory.meta中EquipmentSlot的使用
参数类型为EquipmentSlot的org.bukkit.inventory.meta中的方法修饰符和类型方法说明ItemMeta.getAttributeModifiers(@NotNull EquipmentSlot slot) 返回指定EquipmentSlot的所有属性及其修饰符的不可变列表.booleanItemMeta.removeAttributeModifier(@NotNull EquipmentSlot slot) 为指定的EquipmentSlot移除其所有的属性和属性修饰符.
如果给定的EquipmentSlot为 null, 这将移除所有没有设置EquipmentSlot的AttributeModifier. -
org.bukkit.inventory.meta.components中EquipmentSlot的使用
AttributeModifier.getSlotGroup()