Fix unit tracking to not being limited to the caster of SPELL_AURA_MOD_STALKED, fixes https://github.com/TrinityCore/TrinityCore/issues/6208

This commit is contained in:
The Game
2012-04-17 11:40:58 -04:00
parent 17d87c0103
commit 3bfe59b41d

View File

@@ -626,7 +626,11 @@ void Object::_BuildValuesUpdate(uint8 updatetype, ByteBuffer * data, UpdateMask*
if (!target->isAllowedToLoot(creature))
dynamicFlags &= ~UNIT_DYNFLAG_LOOTABLE;
}
if(Unit const* unit = ToUnit())
{
if(!unit->HasAuraTypeWithCaster(SPELL_AURA_MOD_STALKED, target->GetGUID()))
dynamicFlags &= ~UNIT_DYNFLAG_TRACK_UNIT;
}
*data << dynamicFlags;
}
// FG: pretend that OTHER players in own group are friendly ("blue")