Core/Scripting: Fixed hotswap calling evade mode for dead creatures

This commit is contained in:
sirikfoll authored and Aokromes committed 2017-01-14 06:46:02 +01:00
1 parent 752ba8367e
commit dea47762be
1 file changed
+2 -1
+2 -1
View File
@@ -378,7 +378,8 @@ class CreatureGameObjectScriptRegistrySwapHooks
ASSERT(!creature->IsCharmed(),
"There is a disabled AI which is still loaded.");
creature->AI()->EnterEvadeMode();
if (creature->IsAlive())
creature->AI()->EnterEvadeMode();
}
static void UnloadDestroyScript(Creature* creature)