fix(Scripts/ZulGurub): Shade of Jin'do's invisibility aura should not… (#11838)

* fix(Scripts/ZulGurub): Shade of Jin'do's invisibility aura should not be removed on attack.

Fixes #11557

* missing stuff.

* Update.
This commit is contained in:
UltraNix
2022-06-06 20:20:40 +02:00
committed by GitHub
parent 75858bd786
commit 41b0fa02f2
3 changed files with 20 additions and 6 deletions

View File

@@ -1078,8 +1078,19 @@ namespace Acore
bool operator()(Unit* u)
{
// Check contains checks for: live, non-selectable, non-attackable flags, flight check and GM check, ignore totems
if (u->GetTypeId() == TYPEID_UNIT && ((Creature*)u)->IsTotem())
return false;
if (Creature* creature = u->ToCreature())
{
if (creature->IsTotem())
{
return false;
}
if (creature->IsAvoidingAOE())
{
return false;
}
}
if (i_funit->_IsValidAttackTarget(u, _spellInfo, i_obj->GetTypeId() == TYPEID_DYNAMICOBJECT ? i_obj : nullptr) && i_obj->IsWithinDistInMap(u, i_range))
return true;