Fix Reset Flying NPC to Spawn POINT

This commit is contained in:
KAMKEEL committed 2022-11-07 21:23:46 -05:00
1 parent 45c43a399b
commit cc39e62bd4
1 file changed
+5 -3
@@ -1059,12 +1059,14 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti
killedtime = 0;
extinguish();
this.clearActivePotions();
moveEntityWithHeading(0,0);
distanceWalkedModified = 0;
getNavigator().clearPathEntity();
if(canFly()){
if(this.canFly()){
((PathNavigateFlying)getNavigator()).targetPos = null;
((PathNavigateFlying)getNavigator()).clearPathEntity();
((FlyingMoveHelper)getMoveHelper()).update = false;
}
moveEntityWithHeading(0,0);
distanceWalkedModified = 0;
currentAnimation = EnumAnimation.NONE;
updateHitbox();
updateAI = true;