Guest User

Hitentity

a guest
Jul 2nd, 2014
243
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. public boolean hitEntity(ItemStack par1ItemStack, EntityLivingBase par2EntityLivingBase, EntityLivingBase par3EntityLivingBase)
  2. {
  3.  
  4. if (par2EntityLivingBase.getHealth() == 0 && !par2EntityLivingBase.isEntityAlive()){
  5.  
  6.  
  7. ModLoader.getMinecraftInstance().thePlayer.addChatMessage("YOU KILLED SOMETHING");
  8.  
  9. par3EntityLivingBase.heal(1);
  10.  
  11.  
  12.  
  13. }
  14.  
  15. par1ItemStack.damageItem(1, par3EntityLivingBase);
  16.  
  17.  
  18. return true;
  19.  
  20. }
Advertisement
Add Comment
Please, Sign In to add comment