3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-11-17 13:30:06 +01:00

Correct casting for creature target typechecking

Dieser Commit ist enthalten in:
Nathan Adams 2012-01-14 14:49:41 +00:00
Ursprung e6bb19f63a
Commit 77a12d4dce

Datei anzeigen

@ -24,7 +24,7 @@ public class CraftCreature extends CraftLivingEntity implements Creature {
public CraftLivingEntity getTarget() { public CraftLivingEntity getTarget() {
if (getHandle().target == null) return null; if (getHandle().target == null) return null;
if (!(getHandle().target instanceof CraftLivingEntity)) return null; if (!(getHandle().target instanceof EntityLiving)) return null;
return (CraftLivingEntity) getHandle().target.getBukkitEntity(); return (CraftLivingEntity) getHandle().target.getBukkitEntity();
} }