Fix entity count being incorrect for spawning logic. Now filter out 'persistant' entities.

This commit is contained in:
Lex Manos 2015-09-14 13:18:34 -07:00
parent eacffb2b6e
commit fb9ffa40fd

View file

@ -125,7 +125,7 @@
}
public boolean func_174816_a(Explosion p_174816_1_, World p_174816_2_, BlockPos p_174816_3_, IBlockState p_174816_4_, float p_174816_5_)
@@ -2357,4 +2405,183 @@
@@ -2357,4 +2405,184 @@
EnchantmentHelper.func_151385_b(p_174815_1_, p_174815_2_);
}
@ -238,6 +238,7 @@
+ */
+ public boolean isCreatureType(EnumCreatureType type, boolean forSpawnCount)
+ {
+ if (forSpawnCount && (this instanceof EntityLiving) && ((EntityLiving)this).func_104002_bU()) return false;
+ return type.func_75598_a().isAssignableFrom(this.getClass());
+ }
+