aboutsummaryrefslogtreecommitdiff
path: root/src/game/NullCreatureAI.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-01-28 20:54:54 -0600
committermegamage <none@none>2009-01-28 20:54:54 -0600
commit1d19b6bcca688147814f07503a70a4d676c9b761 (patch)
treebeab22718d8b226ad170ba9e9250bf1f0c892a68 /src/game/NullCreatureAI.cpp
parent30c5bff102bc089bcc18677352bf506ac0219111 (diff)
*Fix the bug that critters do not enterevademode.
--HG-- branch : trunk
Diffstat (limited to 'src/game/NullCreatureAI.cpp')
-rw-r--r--src/game/NullCreatureAI.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/game/NullCreatureAI.cpp b/src/game/NullCreatureAI.cpp
index 67839ab9315..164aa2f7974 100644
--- a/src/game/NullCreatureAI.cpp
+++ b/src/game/NullCreatureAI.cpp
@@ -21,8 +21,10 @@
#include "NullCreatureAI.h"
#include "Creature.h"
-NullCreatureAI::~NullCreatureAI()
+void PassiveAI::UpdateAI(const uint32)
{
+ if(me->isInCombat() && me->getAttackers().empty())
+ EnterEvadeMode();
}
void CritterAI::DamageTaken(Unit *done_by, uint32 &)