void Dropper() { for (int j = 0; j < 20; j++) { double d = rand.nextGaussian() * 0.02D; double d1 = rand.nextGaussian() * 0.02D; double d2 = rand.nextGaussian() * 0.02D; worldObj.spawnParticle( "explode", (posX + (double) (rand.nextFloat() * width * 2.0F)) - (double) width, posY + (double) (rand.nextFloat() * height), (posZ + (double) (rand.nextFloat() * width * 2.0F)) - (double) width, d, d1, d2); } if (!AutomatonUniversal.otherWorld(worldObj)) { entityDropItem(new ItemStack(AutomatonLogger.biter + 256, 1, 0), 0.0F); setEntityDead(); } }
public void onDeath(DamageSource damagesource) { if (!AutomatonUniversal.otherWorld(worldObj)) { Dropper(); // a(field_34905_c > 0); } worldObj.setEntityState(this, (byte) 3); }