This commit is contained in:
Adubbz G 2013-06-23 07:34:48 +10:00
parent 2f210f9e05
commit 13a900e7dd

View file

@ -135,12 +135,13 @@ public class EntityEventHandler
public void entityInteract(EntityInteractEvent event) public void entityInteract(EntityInteractEvent event)
{ {
ItemStack itemstack = event.entityPlayer.getCurrentEquippedItem(); ItemStack itemstack = event.entityPlayer.getCurrentEquippedItem();
int itemDamage = itemstack.getItemDamage();
Entity entity = event.target; Entity entity = event.target;
EntityPlayer player = event.entityPlayer; EntityPlayer player = event.entityPlayer;
if (itemstack != null) if (itemstack != null)
{ {
int itemDamage = itemstack.getItemDamage();
if (itemstack.itemID == Items.soulManipulator.get().itemID && itemstack.getItemDamage() == 2) if (itemstack.itemID == Items.soulManipulator.get().itemID && itemstack.getItemDamage() == 2)
{ {
if (entity instanceof EntityEnderman) if (entity instanceof EntityEnderman)