BFA Update (still lots of testing to do tho)
This commit is contained in:
@@ -261,6 +261,7 @@ namespace Game.AI
|
||||
me.ResetPlayerDamageReq();
|
||||
me.SetLastDamagedTime(0);
|
||||
me.SetCannotReachTarget(false);
|
||||
me.DoNotReacquireTarget();
|
||||
|
||||
if (me.IsInEvadeMode())
|
||||
return false;
|
||||
|
||||
@@ -39,6 +39,12 @@ namespace Game.AI
|
||||
if (me.IsCharmed() && me.GetVictim() == me.GetCharmer())
|
||||
return true;
|
||||
|
||||
// dont allow pets to follow targets far away from owner
|
||||
Unit owner = me.GetCharmerOrOwner();
|
||||
if (owner)
|
||||
if (owner.GetExactDist(me) >= (owner.GetVisibilityRange() - 10.0f))
|
||||
return true;
|
||||
|
||||
return !me.IsValidAttackTarget(me.GetVictim());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user