Enum Class Item.ItemLockMode

java.lang.Object
java.lang.Enum<Item.ItemLockMode>
cn.nukkit.item.Item.ItemLockMode
All Implemented Interfaces:
Serializable, Comparable<Item.ItemLockMode>, Constable
Enclosing class:
Item

@PowerNukkitXOnly @Since("1.6.0.0-PNX") public static enum Item.ItemLockMode extends Enum<Item.ItemLockMode>
物品锁定在玩家的物品栏 LOCK_IN_SLOT 阻止该物品被从玩家物品栏的该槽位移动、移除、丢弃或用于合成 LOCK_IN_INVENTORY 阻止该物品被从玩家的物品栏移除、丢弃或用于合成

Locks the item in the player's inventory LOCK_IN_SLOT Prevents the item from being removed from the player's inventory, dropped, or crafted with. LOCK_IN_INVENTORY Prevents the item from being moved or removed from its slot in the player's inventory, dropped, or crafted with

  • Enum Constant Details

  • Method Details

    • values

      public static Item.ItemLockMode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Item.ItemLockMode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null