@Override public void damage(double amount, Entity source, DamageCause cause) { if (!DamageCause.LIGHTNING.equals(cause)) { super.damage(amount, source, cause); return; } PigZombie pigZombie = world.spawn(this.location, PigZombie.class); pigZombie.damage(amount, source, cause); remove(); }