Improved load animations of NPCs

This commit is contained in:
Eisi05 committed 2026-09-16 15:24:05 +02:00
1 parent 1fd1e72632
commit 5ea67b6ef8
1 file changed
+4 -3
@@ -556,10 +556,11 @@ public class NpcOption<T, S extends Serializable>
else
entity = npc.entity;
Location location = npc.getLocation();
if(npc.getOption(NpcOption.POSE) == org.bukkit.entity.Pose.SITTING)
entity.moveTo(npc.getLocation().clone().subtract(0, npc.getOption(NpcOption.SCALE) * (entity.getDefaultBoundingBox().getYSize() / 3D),0));
else
entity.moveTo(npc.getLocation());
location = location.clone().subtract(0, npc.getOption(NpcOption.SCALE) * (entity.getDefaultBoundingBox().getYSize() / 3D),0);
entity.moveTo(location);
npc.serverPlayer.getNameTag().moveTo(location.clone().add(0, 0.25 + npc.getNpcName().getDisplayOptions().getHeight(), 0));
npc.entity = entity;
if(entity instanceof WrappedEnderDragon dragon)