diff options
author | QAston <> | 2010-02-20 20:28:31 +0100 |
---|---|---|
committer | QAston <> | 2010-02-20 20:28:31 +0100 |
commit | 2e3f89b61fa33e83b8f70702777549e25e5fc481 (patch) | |
tree | 904060daaf9fb782a20e5b2aea3e9febe813de65 /src/game/SpellEffects.cpp | |
parent | 4cd4c4170f70a0715daad52b2f1831b6017d647a (diff) | |
parent | 8e146c309de73160252ae538689d28660273d459 (diff) |
*Move summon water elemental handler to correct place.
--HG--
branch : trunk
Diffstat (limited to 'src/game/SpellEffects.cpp')
-rw-r--r-- | src/game/SpellEffects.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index 48ce576b38d..844b1808675 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -6836,7 +6836,15 @@ void Spell::EffectPlayerPull(uint32 i) if(!unitTarget) return; - unitTarget->GetMotionMaster()->MoveJump(m_caster->GetPositionX(), m_caster->GetPositionY(), m_caster->GetPositionZ(), float(damage ? damage : unitTarget->GetDistance2d(m_caster)), float(m_spellInfo->EffectMiscValue[i])/10); + float speedZ; + if(m_spellInfo->EffectMiscValue[i]) + speedZ = float(m_spellInfo->EffectMiscValue[i])/10; + else if(m_spellInfo->EffectMiscValueB[i]) + speedZ = float(m_spellInfo->EffectMiscValueB[i])/10; + else + speedZ = 10.0f; + float speedXY = m_caster->GetExactDist2d(unitTarget) * 10.0f / speedZ; + unitTarget->GetMotionMaster()->MoveJump(m_caster->GetPositionX(), m_caster->GetPositionY(), m_caster->GetPositionZ(), speedXY, speedZ); } void Spell::EffectDispelMechanic(uint32 i) |