*Allow not to switch to charmed AI for some scripts.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-03-13 17:48:57 -06:00
parent 5f2edfc7e8
commit ce4c9cb2ae
4 changed files with 14 additions and 4 deletions
+6 -1
View File
@@ -484,7 +484,12 @@ void Creature::Update(uint32 diff)
break;
// if creature is charmed, switch to charmed AI
UpdateCharmAI();
if(NeedChangeAI)
{
UpdateCharmAI();
NeedChangeAI = false;
IsAIEnabled = true;
}
if(!IsInEvadeMode() && IsAIEnabled)
{