Commits

Thinkofname authored and md_5 committed a21d8c465bd
Implement API for "main hand" and "off hand" slots.

Also deprecate existing "hand" API as it is not specific about which hand is being referred to. Implementations should default this method to the "main hand".
No tags

src/main/java/org/bukkit/entity/HumanEntity.java

Modified
98 98
99 99 /**
100 100 * Force-closes the currently open inventory view for this player, if any.
101 101 */
102 102 public void closeInventory();
103 103
104 104 /**
105 105 * Returns the ItemStack currently in your hand, can be empty.
106 106 *
107 107 * @return The ItemStack of the item you are currently holding.
108 + * @deprecated Humans may now dual wield in their off hand, use explicit
109 + * methods in {@link PlayerInventory}.
108 110 */
111 + @Deprecated
109 112 public ItemStack getItemInHand();
110 113
111 114 /**
112 115 * Sets the item to the given ItemStack, this will replace whatever the
113 116 * user was holding.
114 117 *
115 118 * @param item The ItemStack which will end up in the hand
119 + * @deprecated Humans may now dual wield in their off hand, use explicit
120 + * methods in {@link PlayerInventory}.
116 121 */
122 + @Deprecated
117 123 public void setItemInHand(ItemStack item);
118 124
119 125 /**
120 126 * Returns the ItemStack currently on your cursor, can be empty. Will
121 127 * always be empty if the player currently has no open window.
122 128 *
123 129 * @return The ItemStack of the item you are currently moving around.
124 130 */
125 131 public ItemStack getItemOnCursor();
126 132

Everything looks good. We'll let you know here if there's anything you should know about.

Add shortcut