From 39dc2d1c4db526d3ad13919f238f0998b2bf2654 Mon Sep 17 00:00:00 2001 From: megamage Date: Wed, 6 May 2009 17:00:11 -0500 Subject: [PATCH] *Use custom spell intead of hard code for EffectDestroyAllTotems. By Maxxie --HG-- branch : trunk --- src/game/SpellEffects.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index ffb3a38c9f..5d4ef83ed1 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -6015,7 +6015,7 @@ void Spell::EffectSummonDeadPet(uint32 /*i*/) void Spell::EffectDestroyAllTotems(uint32 /*i*/) { - float mana = 0; + int32 mana = 0; for(int slot = SUMMON_SLOT_TOTEM; slot < MAX_TOTEM_SLOT; ++slot) { if(!m_caster->m_SummonSlot[slot]) @@ -6036,8 +6036,8 @@ void Spell::EffectDestroyAllTotems(uint32 /*i*/) } mana = mana * damage / 100; - int32 gain = m_caster->ModifyPower(POWER_MANA,int32(mana)); - m_caster->SendEnergizeSpellLog(m_caster, m_spellInfo->Id, gain, POWER_MANA); + if (mana) + m_caster->CastCustomSpell(m_caster, 39104, &mana, NULL, NULL, true); } void Spell::EffectDurabilityDamage(uint32 i)