Core/Unit: send npcs home after fear runs out (#25347)

* Core/Unit: send npcs home after fear runs out

* Whoops, wrong
This commit is contained in:
Jinnaix
2020-08-29 14:31:58 +02:00
committed by GitHub
parent 92f9abab06
commit 7e6f17a701

View File

@@ -11391,6 +11391,8 @@ void Unit::SetFeared(bool apply)
GetMotionMaster()->Remove(FLEEING_MOTION_TYPE);
if (GetVictim())
SetTarget(EnsureVictim()->GetGUID());
if (!IsPlayer() && !IsInCombat())
GetMotionMaster()->MoveTargetedHome();
}
}