aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormegamage <none@none>2009-05-03 11:49:41 -0500
committermegamage <none@none>2009-05-03 11:49:41 -0500
commit2e364b61027dc67ac729b96af290e25d2015db39 (patch)
tree69ce434b0c6d720f24d945aec1d32e4cf2dd02bb /src
parentea034a860362a5549128c57ef80684ea3b95568c (diff)
*Fix broken chain spells.
--HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/game/Spell.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/game/Spell.cpp b/src/game/Spell.cpp
index eca8051ce97..4c2fe39ee1b 100644
--- a/src/game/Spell.cpp
+++ b/src/game/Spell.cpp
@@ -1983,7 +1983,7 @@ void Spell::SetTargetMap(uint32 i, uint32 cur)
m_damageMultipliers[i] = 1.0f;
m_applyMultiplierMask |= 1 << i;
- float radius;
+ float range;
std::list<Unit*> unitList;
switch(cur)
@@ -1991,17 +1991,17 @@ void Spell::SetTargetMap(uint32 i, uint32 cur)
case TARGET_UNIT_NEARBY_ENEMY:
case TARGET_UNIT_TARGET_ENEMY:
case TARGET_UNIT_NEARBY_ENTRY: // fix me
- radius = GetSpellRadius(m_spellInfo, i, false);
- if(modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RADIUS, radius, this);
- SearchChainTarget(unitList, radius, maxTargets, SPELL_TARGETS_ENEMY);
+ range = GetSpellMaxRange(m_spellInfo, false);
+ if(modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RANGE, range, this);
+ SearchChainTarget(unitList, range, maxTargets, SPELL_TARGETS_ENEMY);
break;
case TARGET_UNIT_CHAINHEAL:
case TARGET_UNIT_NEARBY_ALLY: // fix me
case TARGET_UNIT_NEARBY_ALLY_UNK:
case TARGET_UNIT_NEARBY_RAID:
- radius = GetSpellRadius(m_spellInfo, i, true);
- if(modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RADIUS, radius, this);
- SearchChainTarget(unitList, radius, maxTargets, SPELL_TARGETS_CHAINHEAL);
+ range = GetSpellMaxRange(m_spellInfo, true);
+ if(modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RANGE, range, this);
+ SearchChainTarget(unitList, range, maxTargets, SPELL_TARGETS_CHAINHEAL);
break;
}