mirror of
https://github.com/liyunfan1223/azerothcore-wotlk.git
synced 2026-08-08 07:48:02 +00:00
fix(Core/GridNotifiers): fix ImmuneToPC npcs reacting to stealthed players (#21652)
This commit is contained in:
@@ -131,6 +131,12 @@ inline void CreatureUnitRelocationWorker(Creature* c, Unit* u)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Prevents AI reaction when immunity flags are active
|
||||||
|
if (c->IsImmuneToNPC())
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (!c->HasUnitState(UNIT_STATE_SIGHTLESS))
|
if (!c->HasUnitState(UNIT_STATE_SIGHTLESS))
|
||||||
{
|
{
|
||||||
if (c->IsAIEnabled && c->CanSeeOrDetect(u, false, true))
|
if (c->IsAIEnabled && c->CanSeeOrDetect(u, false, true))
|
||||||
|
|||||||
Reference in New Issue
Block a user