Core/Spells: Implemented spell effect 202 SPELL_EFFECT_APPLY_AREA_AURA_SUMMONS

Port From (https://github.com/TrinityCore/TrinityCore/commit/ad479e8fa0de6659815e956ee5f2b594957a7d1d)
This commit is contained in:
hondacrx
2021-03-04 14:21:45 -05:00
parent 80d12a5d58
commit 42f411119a
5 changed files with 18 additions and 6 deletions
+9 -1
View File
@@ -2602,7 +2602,7 @@ namespace Game.Spells
List<Unit> targetList = new List<Unit>();
// non-area aura
if (effect.Effect == SpellEffectName.ApplyAura || effect.Effect == SpellEffectName.Unk202)
if (effect.Effect == SpellEffectName.ApplyAura)
{
targetList.Add(GetUnitOwner());
}
@@ -2657,6 +2657,14 @@ namespace Game.Spells
targetList.Add(pet);
break;
}
case SpellEffectName.ApplyAreaAuraSummons:
{
targetList.Add(GetUnitOwner());
WorldObjectSpellAreaTargetCheck check = new(radius, GetUnitOwner(), caster, GetUnitOwner(), GetSpellInfo(), SpellTargetCheckTypes.Summoned, null, SpellTargetObjectTypes.Unit);
UnitListSearcher searcher = new(GetUnitOwner(), targetList, check);
Cell.VisitAllObjects(GetUnitOwner(), searcher, radius);
break;
}
}
}
}