From ae1f60c27f47dc80f70af43ce997012307c6c969 Mon Sep 17 00:00:00 2001 From: DiSlord Date: Mon, 12 Jan 2009 21:21:00 +0300 Subject: [PATCH] Use CastSpell(x,y,z ... for EffectTriggerMissileSpell Signed-off-by: DiSlord --- src/game/SpellEffects.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index 8671be397..ce04e764d 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -1983,12 +1983,7 @@ void Spell::EffectTriggerMissileSpell(uint32 effect_idx) if (m_CastItem) DEBUG_LOG("WORLD: cast Item spellId - %i", spellInfo->Id); - Spell *spell = new Spell(m_caster, spellInfo, true, m_originalCasterGUID ); - - SpellCastTargets targets; - targets.setDestination(m_targets.m_destX,m_targets.m_destY,m_targets.m_destZ); - spell->m_CastItem = m_CastItem; - spell->prepare(&targets, NULL); + m_caster->CastSpell(m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, spellInfo, true, m_CastItem, 0, m_originalCasterGUID); } void Spell::EffectTeleportUnits(uint32 i)