Core/Spells: use a more reliable check for personal gnoll summons
This commit is contained in:
1 parent
ed1b1ada94
commit
9d1a0b85f4
1 file changed
+8
-2
@@ -1786,7 +1786,14 @@ class GnollHolderTargetSelector
|
||||
|
||||
bool operator() (WorldObject* target)
|
||||
{
|
||||
return !_caster->CanSeeOrDetect(target);
|
||||
if (target->GetTypeId() != TYPEID_UNIT)
|
||||
return true;
|
||||
|
||||
if (TempSummon* summon = target->ToUnit()->ToTempSummon())
|
||||
if (summon->GetSummoner() == _caster)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
private:
|
||||
@@ -1869,7 +1876,6 @@ class spell_darkmoon_island_whack : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_darkmoon_island_whack);
|
||||
|
||||
|
||||
void FilterTargets(std::list<WorldObject*>& targets)
|
||||
{
|
||||
if (targets.empty())
|
||||
|
||||
Reference in new issue
Block a user