13
0
geforkt von Mirrors/Paper

Properly clear attributes on remove and death. Fixes BUKKIT-4416

By: EvilSeph <evilseph@gmail.com>
Dieser Commit ist enthalten in:
CraftBukkit/Spigot 2013-07-03 00:23:34 -04:00
Ursprung 48a3e72018
Commit 6addfb0dff

Datei anzeigen

@ -275,12 +275,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
}
public void removePotionEffect(PotionEffectType type) {
getHandle().effects.remove(type.getId());
getHandle().updateEffects = true;
if (getHandle() instanceof EntityPlayer) {
if (((EntityPlayer) getHandle()).playerConnection == null) return;
((EntityPlayer) getHandle()).playerConnection.sendPacket(new Packet42RemoveMobEffect(getHandle().id, new MobEffect(type.getId(), 0, 0)));
}
getHandle().k(type.getId()); // Should be removeEffect.
}
public Collection<PotionEffect> getActivePotionEffects() {