diff --git a/xiaofang/Assets/Script/npc/RecuseNpc.cs b/xiaofang/Assets/Script/npc/RecuseNpc.cs index ce8d71e4..1da2ce81 100644 --- a/xiaofang/Assets/Script/npc/RecuseNpc.cs +++ b/xiaofang/Assets/Script/npc/RecuseNpc.cs @@ -89,6 +89,20 @@ public class RecuseNpc : MonoBehaviour private void Update() { + // 继续处理NPC的状态和动画 + switch (nstate) + { + case Npcstate.idle: + SetAni(2); + break; + case Npcstate.run: + movebool = true; + Run(currentTarget); + break; + case Npcstate.dead: + SetAni(0); + break; + } if (targetPoints.Count > 0) // 确保列表中有目标点 { @@ -118,20 +132,7 @@ public class RecuseNpc : MonoBehaviour } } - // 继续处理NPC的状态和动画 - switch (nstate) - { - case Npcstate.idle: - SetAni(2); - break; - case Npcstate.run: - movebool = true; - Run(currentTarget); - break; - case Npcstate.dead: - SetAni(0); - break; - } + } //移除第一个点