[Bleeding] Ensure skeletons spawn with equipment. Fixes BUKKIT-2836

Previously, when a skeleton was spawned via the spawn(...) function, the
resulting skeleton had no equipped bow and therefore could not properly
attack. This fix gives all skeletons the proper equipment and ensures that
they are able to attack.

By: GJ <gjmcferrin@gmail.com>
This commit is contained in:
CraftBukkit/Spigot 2014-02-11 22:22:39 -05:00
parent 42f39726c3
commit f612d70b0d

View file

@ -1032,6 +1032,10 @@ public class CraftWorld implements World {
}
if (entity != null) {
if (entity instanceof EntityInsentient) {
((EntityInsentient) entity).a((GroupDataEntity) null); // Should be prepare?
}
world.addEntity(entity, reason);
return (T) entity.getBukkitEntity();
}