Enum Class ItemAction

java.lang.Object
java.lang.Enum<ItemAction>
ru.cwcode.cwutils.items.activeItem.ItemAction
All Implemented Interfaces:
Serializable, Comparable<ItemAction>, java.lang.constant.Constable

public enum ItemAction extends Enum<ItemAction>
  • Enum Constant Details

    • LEFT_CLICK_BLOCK

      public static final ItemAction LEFT_CLICK_BLOCK
    • RIGHT_CLICK_BLOCK

      public static final ItemAction RIGHT_CLICK_BLOCK
      Right-clicking a block
    • LEFT_CLICK_AIR

      public static final ItemAction LEFT_CLICK_AIR
      Left-clicking the air
    • RIGHT_CLICK_AIR

      public static final ItemAction RIGHT_CLICK_AIR
      Right-clicking the air
    • NOTHING

      public static final ItemAction NOTHING
    • PICKUP_ALL

      public static final ItemAction PICKUP_ALL
      All of the items on the clicked slot are moved to the cursor.
    • PICKUP_SOME

      public static final ItemAction PICKUP_SOME
      Some of the items on the clicked slot are moved to the cursor.
    • PICKUP_HALF

      public static final ItemAction PICKUP_HALF
      Half of the items on the clicked slot are moved to the cursor.
    • PICKUP_ONE

      public static final ItemAction PICKUP_ONE
      One of the items on the clicked slot are moved to the cursor.
    • PLACE_ALL

      public static final ItemAction PLACE_ALL
      All of the items on the cursor are moved to the clicked slot.
    • PLACE_SOME

      public static final ItemAction PLACE_SOME
      Some of the items from the cursor are moved to the clicked slot (usually up to the max stack size).
    • PLACE_ONE

      public static final ItemAction PLACE_ONE
      A single item from the cursor is moved to the clicked slot.
    • SWAP_WITH_CURSOR

      public static final ItemAction SWAP_WITH_CURSOR
      The clicked item and the cursor are exchanged.
    • DROP_ALL_CURSOR

      public static final ItemAction DROP_ALL_CURSOR
      The entire cursor item is dropped.
    • DROP_ONE_CURSOR

      public static final ItemAction DROP_ONE_CURSOR
      One item is dropped from the cursor.
    • DROP_ALL_SLOT

      public static final ItemAction DROP_ALL_SLOT
      The entire clicked slot is dropped.
    • DROP_ONE_SLOT

      public static final ItemAction DROP_ONE_SLOT
      One item is dropped from the clicked slot.
    • MOVE_TO_OTHER_INVENTORY

      public static final ItemAction MOVE_TO_OTHER_INVENTORY
      The item is moved to the opposite inventory if a space is found.
    • HOTBAR_MOVE_AND_READD

      public static final ItemAction HOTBAR_MOVE_AND_READD
      The clicked item is moved to the hotbar, and the item currently there is re-added to the player's inventory.

      The hotbar includes the player's off hand.

    • HOTBAR_SWAP

      public static final ItemAction HOTBAR_SWAP
      The clicked slot and the picked hotbar slot are swapped.

      The hotbar includes the player's off hand.

    • CLONE_STACK

      public static final ItemAction CLONE_STACK
      A max-size stack of the clicked item is put on the cursor.
    • COLLECT_TO_CURSOR

      public static final ItemAction COLLECT_TO_CURSOR
      The inventory is searched for the same material, and they are put on the cursor up to Material.getMaxStackSize().
    • UNKNOWN

      public static final ItemAction UNKNOWN
      An unrecognized ClickType.
    • LEFT

      public static final ItemAction LEFT
    • SHIFT_LEFT

      public static final ItemAction SHIFT_LEFT
      Holding shift while pressing the left mouse button.
    • SHIFT_RIGHT

      public static final ItemAction SHIFT_RIGHT
      Holding shift while pressing the right mouse button.
    • WINDOW_BORDER_LEFT

      public static final ItemAction WINDOW_BORDER_LEFT
      Clicking the left mouse button on the grey area around the inventory.
    • WINDOW_BORDER_RIGHT

      public static final ItemAction WINDOW_BORDER_RIGHT
      Clicking the right mouse button on the grey area around the inventory.
    • MIDDLE

      public static final ItemAction MIDDLE
      The middle mouse button, or a "scrollwheel click".
    • NUMBER_KEY

      public static final ItemAction NUMBER_KEY
      One of the number keys 1-9, correspond to slots on the hotbar.
    • DOUBLE_CLICK

      public static final ItemAction DOUBLE_CLICK
      Pressing the left mouse button twice in quick succession.
    • DROP

      public static final ItemAction DROP
      The "Drop" key (defaults to Q) in inventory.
    • CONTROL_DROP

      public static final ItemAction CONTROL_DROP
      Holding Ctrl while pressing the "Drop" key (defaults to Q) in inventory.
    • CREATIVE

      public static final ItemAction CREATIVE
      Any action done with the Creative inventory open.
    • SWAP_OFFHAND

      public static final ItemAction SWAP_OFFHAND
      The "swap item with offhand" key (defaults to F).
    • DROP_ITEM_EVENT

      public static final ItemAction DROP_ITEM_EVENT
      Drop item in world (with closed inventory press the "Drop" key (defaults to Q)
  • Method Details

    • values

      public static ItemAction[] 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 ItemAction 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