mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-22 13:09:42 +00:00
The Pixies the Gaia Guardian spawns no longer take non-player damage.
This commit is contained in:
1 parent
a3cae0f71b
commit
a8a6bec1a8
1 file changed
+1
-2
@@ -40,7 +40,6 @@ public class EntityPixie extends EntityFlyingCreature {
|
||||
getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(2.0);
|
||||
}
|
||||
|
||||
|
||||
public void setType(int type) {
|
||||
dataWatcher.updateObject(20, type);
|
||||
}
|
||||
@@ -90,7 +89,7 @@ public class EntityPixie extends EntityFlyingCreature {
|
||||
|
||||
@Override
|
||||
public boolean attackEntityFrom(DamageSource par1DamageSource, float par2) {
|
||||
if(par1DamageSource.getEntity() != summoner)
|
||||
if((getType() == 0 && par1DamageSource.getEntity() != summoner) || (getType() == 1 && par1DamageSource.getDamageType().equals("player")))
|
||||
return super.attackEntityFrom(par1DamageSource, par2);
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user