mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
Implement 277 SPELL_AURA_MOD_MAX_AFFECTED_TARGETS
Signed-off-by: DiSlord <dislord@nomail.com>
This commit is contained in:
parent
2c1f19d997
commit
213a10dcbd
3 changed files with 10 additions and 2 deletions
|
|
@ -1186,7 +1186,15 @@ void Spell::SetTargetMap(uint32 i,uint32 cur,std::list<Unit*> &TagUnitMap)
|
|||
if(Player* modOwner = m_originalCaster->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_JUMP_TARGETS, EffectChainTarget, this);
|
||||
|
||||
// Get spell max affected targets
|
||||
uint32 unMaxTargets = m_spellInfo->MaxAffectedTargets;
|
||||
Unit::AuraList const& mod = m_caster->GetAurasByType(SPELL_AURA_MOD_MAX_AFFECTED_TARGETS);
|
||||
for(Unit::AuraList::const_iterator m = mod.begin(); m != mod.end(); ++m)
|
||||
{
|
||||
if (!(*m)->isAffectedOnSpell(m_spellInfo))
|
||||
continue;
|
||||
unMaxTargets+=(*m)->GetModifier()->m_amount;
|
||||
}
|
||||
switch(cur)
|
||||
{
|
||||
case TARGET_TOTEM_EARTH:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue