feat(Core): port aggro distance from vMaNGOS (#6214)

Read detection_range values from creature_template
This commit is contained in:
Shiroe
2021-07-08 18:01:27 +02:00
committed by GitHub
parent 6fa2ad4e33
commit f8c8e98a0a
15 changed files with 89 additions and 72 deletions

View File

@@ -280,7 +280,7 @@ struct boss_twinemperorsAI : public ScriptedAI
if (me->_CanDetectFeignDeathOf(who) && me->CanCreatureAttack(who))
{
if (me->IsWithinDistInMap(who, PULL_RANGE) && me->GetDistanceZ(who) <= /*CREATURE_Z_ATTACK_RANGE*/7 /*there are stairs*/)
if (me->IsWithinDistInMap(who, PULL_RANGE, true, false) && me->GetDistanceZ(who) <= /*CREATURE_Z_ATTACK_RANGE*/7 /*there are stairs*/)
{
//if (who->HasStealthAura())
// who->RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);