Core/SAI: Using SMART_ACTION_SET_FOLLOW with target_type 0 (SMART_TARGET_NONE) will now stop the following completely. Fixes 6 scripts in a clean TDB already using this functionality even though it wasn't implemented.

This commit is contained in:
Discover-
2013-12-17 10:12:23 +01:00
parent 54b7162f1d
commit 20a22662df
3 changed files with 33 additions and 19 deletions

View File

@@ -825,7 +825,10 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
ObjectList* targets = GetTargets(e, unit);
if (!targets)
{
CAST_AI(SmartAI, me->AI())->StopFollow();
break;
}
for (ObjectList::const_iterator itr = targets->begin(); itr != targets->end(); ++itr)
{