diff options
| author | Shauren <shauren.dev@gmail.com> | 2011-01-02 21:33:37 +0100 |
|---|---|---|
| committer | Shauren <shauren.dev@gmail.com> | 2011-01-02 21:33:37 +0100 |
| commit | 9c0cd63e933ece1a9b878b90103b305358202d25 (patch) | |
| tree | 03f63fa2a44ea6af7c1989c0b7979ba28b3feb06 /src/server/game/AI/ScriptedAI | |
| parent | c2f98606b2d0c33f13b55c07c4c0e55d3d959676 (diff) | |
Core/Scripts: Added wrapper method for despawning creatures DespawnOrUnsummon
Diffstat (limited to 'src/server/game/AI/ScriptedAI')
| -rw-r--r-- | src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp | 4 | ||||
| -rw-r--r-- | src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp index 330c13ba01e..c41ce1881d8 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp @@ -246,7 +246,7 @@ void npc_escortAI::UpdateAI(const uint32 uiDiff) me->Respawn(); } else - me->ForcedDespawn(); + me->DespawnOrUnsummon(); return; } @@ -287,7 +287,7 @@ void npc_escortAI::UpdateAI(const uint32 uiDiff) me->Respawn(); } else - me->ForcedDespawn(); + me->DespawnOrUnsummon(); return; } diff --git a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp index 415d4dcc07a..06fb3bc667a 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp @@ -192,7 +192,7 @@ void FollowerAI::UpdateAI(const uint32 uiDiff) if (HasFollowState(STATE_FOLLOW_COMPLETE) && !HasFollowState(STATE_FOLLOW_POSTEVENT)) { sLog->outDebug("TSCR: FollowerAI is set completed, despawns."); - me->ForcedDespawn(); + me->DespawnOrUnsummon(); return; } @@ -232,7 +232,7 @@ void FollowerAI::UpdateAI(const uint32 uiDiff) if (bIsMaxRangeExceeded) { sLog->outDebug("TSCR: FollowerAI failed because player/group was to far away or not found"); - me->ForcedDespawn(); + me->DespawnOrUnsummon(); return; } @@ -266,7 +266,7 @@ void FollowerAI::MovementInform(uint32 uiMotionType, uint32 uiPointId) AddFollowState(STATE_FOLLOW_RETURNING); } else - me->ForcedDespawn(); + me->DespawnOrUnsummon(); } } |
