From 9126cd99d201a69d6aee734468df47f39ab1f53f Mon Sep 17 00:00:00 2001 From: QAston Date: Sat, 18 Jul 2009 15:54:38 +0200 Subject: *Innervate calculation formula update. --HG-- branch : trunk --- src/game/SpellAuras.cpp | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index 15fa3bb88a3..c0b130b6bdf 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -4594,15 +4594,20 @@ void AuraEffect::HandlePeriodicTriggerSpellWithValue(bool apply, bool Real, bool void AuraEffect::HandlePeriodicEnergize(bool apply, bool Real, bool changeAmount) { - if(!Real && !changeAmount) + if(!Real) return; m_isPeriodic = apply; - // Replenishment (0.25% from max) - // Infinite Replenishment - if (m_spellProto->SpellIconID == 3184 && m_spellProto->SpellVisual[0] == 12495) - m_amount = m_target->GetMaxPower(POWER_MANA) * 25 / 10000; + if (apply) + { + // Replenishment (0.25% from max) + // Infinite Replenishment + if (m_spellProto->SpellIconID == 3184 && m_spellProto->SpellVisual[0] == 12495) + m_amount = m_target->GetMaxPower(POWER_MANA) * 25 / 10000; + else if (m_spellProto->Id == 29166) // Innervate + m_amount = m_target->GetCreatePowers(POWER_MANA) * m_amount / ((GetParentAura()->GetAuraMaxDuration() / 10.0f) * (m_amplitude / IN_MILISECONDS)); + } } void AuraEffect::HandleAuraPowerBurn(bool apply, bool Real, bool /*changeAmount*/) -- cgit v1.2.3