Incorrect AI aggression as a consequence of the LineOfSight change, episode three, revenge of the special AIs. Also, hopefully the last. No original trilogy please.

This commit is contained in:
treeston committed 2016-02-20 03:13:11 +01:00
1 parent e4dfbb60fd
commit ab194d5ae3
3 files changed
+5 -2

No files matched your search

@@ -102,7 +102,7 @@ bool FollowerAI::AssistPlayerInCombat(Unit* who)
void FollowerAI::MoveInLineOfSight(Unit* who)
{
if (!me->HasUnitState(UNIT_STATE_STUNNED) && who->isTargetableForAttack() && who->isInAccessiblePlaceFor(me))
if (me->HasReactState(REACT_AGGRESSIVE) && !me->HasUnitState(UNIT_STATE_STUNNED) && who->isTargetableForAttack() && who->isInAccessiblePlaceFor(me))
{
if (HasFollowState(STATE_FOLLOW_INPROGRESS) && AssistPlayerInCombat(who))
return;