mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-12 16:27:37 +00:00
Damaging lens changes.
This commit is contained in:
1 parent
26119318f6
commit
386a2b324f
1 file changed
+2
-2
@@ -237,14 +237,14 @@ public class ItemLens extends ItemMod implements ILens {
|
||||
break;
|
||||
}
|
||||
case DAMAGE : {
|
||||
if(pos.entityHit != null && pos.entityHit instanceof EntityLivingBase) {
|
||||
if(pos.entityHit != null && pos.entityHit instanceof EntityLivingBase && !(pos.entityHit instanceof EntityPlayer)) {
|
||||
EntityLivingBase living = (EntityLivingBase) pos.entityHit;
|
||||
if(living.hurtTime == 0) {
|
||||
int mana = burst.getMana();
|
||||
if(mana >= 16) {
|
||||
burst.setMana(mana - 16);
|
||||
if(!burst.isFake() && !entity.worldObj.isRemote)
|
||||
living.attackEntityFrom(DamageSource.magic, 2);
|
||||
living.attackEntityFrom(DamageSource.magic, 4);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user