Core/NPC: Creatures now alert when they detect stealthed players (#1060)
Creatures stop when they detect a stealthed player like in retail. Closes #1020
This commit is contained in:
parent
59f0d086a6
commit
4b6342b42f
13 changed files with 166 additions and 20 deletions
|
|
@ -89,7 +89,14 @@ void FollowerAI::MoveInLineOfSight(Unit* who)
|
|||
return;
|
||||
|
||||
if (me->CanStartAttack(who))
|
||||
{
|
||||
if (me->HasUnitState(UNIT_STATE_DISTRACTED))
|
||||
{
|
||||
me->ClearUnitState(UNIT_STATE_DISTRACTED);
|
||||
me->GetMotionMaster()->Clear();
|
||||
}
|
||||
AttackStart(who);
|
||||
}
|
||||
}
|
||||
|
||||
void FollowerAI::JustDied(Unit* /*pKiller*/)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue