mirror of
https://github.com/EssentialsX/Essentials.git
synced 2025-01-02 14:37:46 +01:00
why do we even remove the items?
derp
This commit is contained in:
parent
af10a2050a
commit
69e941670f
@ -39,12 +39,11 @@ public class Commandhat extends EssentialsCommand
|
||||
{
|
||||
if (user.getItemInHand().getType() != Material.AIR)
|
||||
{
|
||||
final ItemStack hand = user.getItemInHand().clone();
|
||||
final ItemStack hand = user.getItemInHand();
|
||||
if (hand.getType().getMaxDurability() == 0)
|
||||
{
|
||||
final PlayerInventory inv = user.getInventory();
|
||||
final ItemStack head = inv.getHelmet();
|
||||
inv.removeItem(hand);
|
||||
inv.setHelmet(hand);
|
||||
inv.setItemInHand(head);
|
||||
user.sendMessage(_("hatPlaced"));
|
||||
|
Loading…
Reference in New Issue
Block a user