Jump to content

[fix]Divine Storm(healing)


Auntie Mangos

Recommended Posts

What bug does the patch fix? What features does the patch add?

fixes healing part of Divine Storm

For which repository revision was the patch created?

9457

Is there a thread in the bug report section or at lighthouse? If yes, please add a link to the thread.

http://getmangos.eu/community/showthread.php?11978-%5BSpell-Bug%5D-Divine-Storm

http://getmangos.eu/community/showthread.php?10626-%5BBUG%5D%5B8734%5DDivine-Storm

http://getmangos.eu/community/showthread.php?9613-%5BBug-R8372%5D-Divine-Storm

Who has been writing this patch? Please include either forum user names or email addresses.

me

diff --git a/src/game/Spell.cpp b/src/game/Spell.cpp
index 02d985d..58536df 100644
--- a/src/game/Spell.cpp
+++ b/src/game/Spell.cpp
@@ -1019,6 +1019,10 @@ void Spell::DoAllEffectOnTarget(TargetInfo *target)
            (m_spellInfo->SpellFamilyFlags & UI64LIT(0x0004000000000000)))
            if(Aura* dummy = unitTarget->GetDummyAura(m_spellInfo->Id))
                dummy->GetModifier()->m_amount = damageInfo.damage;
+        
+        // Divine Storm (use m_healthLeech to store damage for all targets)
+        if (m_spellInfo->Id == 53385)
+            m_healthLeech += damageInfo.damage;

        caster->DealSpellDamage(&damageInfo, true);
    }
@@ -1702,6 +1706,8 @@ void Spell::SetTargetMap(SpellEffectIndex effIndex, uint32 targetMode, UnitList&
                FillRaidOrPartyManaPriorityTargets(targetUnitMap, m_caster, m_caster, radius, 10, true, false, true);
            else if (m_spellInfo->Id==52759)                // Ancestral Awakening (special target selection)
                FillRaidOrPartyHealthPriorityTargets(targetUnitMap, m_caster, m_caster, radius, 1, true, false, true);
+            else if (m_spellInfo->Id == 54171)              // Divine Storm
+                FillRaidOrPartyHealthPriorityTargets(targetUnitMap, m_caster, m_caster, radius, 3, true, false, true);
            else
                FillRaidOrPartyTargets(targetUnitMap, m_caster, m_caster, radius, true, true, true);
            break;
@@ -3071,7 +3077,13 @@ void Spell::finish(bool ok)

    // Heal caster for all health leech from all targets
    if (m_healthLeech)
-        m_caster->DealHeal(m_caster, uint32(m_healthLeech), m_spellInfo);
+        if (m_spellInfo->Id == 53385)
+        {
+            int32 bp = int32(m_spellInfo->CalculateSimpleValue(EFFECT_INDEX_1) * m_healthLeech / 100);
+            m_caster->CastCustomSpell(m_caster, 54171, &bp, NULL, NULL, true);
+        }
+        else
+            m_caster->DealHeal(m_caster, uint32(m_healthLeech), m_spellInfo);

    if (IsMeleeAttackResetSpell())
    {
diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp
index 687850e..1e82b72 100644
--- a/src/game/SpellEffects.cpp
+++ b/src/game/SpellEffects.cpp
@@ -1452,6 +1452,13 @@ void Spell::EffectDummy(SpellEffectIndex eff_idx)
                    m_caster->CastSpell(m_caster, 54586, true);
                    return;
                }
+                case 54171:                                 // Divine Storm
+                {
+                    // split between targets
+                    int32 bp = damage / m_UniqueTargetInfo.size();
+                    m_caster->CastCustomSpell(unitTarget, 54172, &bp, NULL, NULL, true);
+                    return;
+                }
                case 55004:                                 // Nitro Boosts
                {
                    if (!m_CastItem)

Link to comment
Share on other sites

  • 40 years later...

I replaced part ( in laise's patch ) where is casted 54171 with code below to make glyph working

@@ -3169,8 +3173,18 @@ void Spell::finish(bool ok)

    // Heal caster for all health leech from all targets
    if (m_healthLeech)
-        m_caster->DealHeal(m_caster, uint32(m_healthLeech), m_spellInfo);
-
+    {
+        // Divine Storm heal calculation
+        if (m_spellInfo->Id == 53385)
+        {
+            SpellEffectIndex healEffIndex = EFFECT_INDEX_1;
+            int32 healAmount = m_caster->CalculateSpellDamage(m_spellInfo, healEffIndex, m_currentBasePoints[healEffIndex], m_caster);
+            healAmount = int32(m_healthLeech * healAmount / 100);
+            m_caster->CastCustomSpell(m_caster, 54171, &healAmount, NULL, NULL, true);
+        }
+        else
+            m_caster->DealHeal(m_caster, uint32(m_healthLeech), m_spellInfo);
+    }
    if (IsMeleeAttackResetSpell())
    {
        m_caster->resetAttackTimer(BASE_ATTACK);

Link to comment
Share on other sites

now i get player feedbacks, the Divine Storm the range is extrem to hight ( heal range ), only 8 yards from wowhead info, but u get 43 yards ingame ( heal range), any idea to fixed ? ( http://www.wowhead.com/?spell=53385 )

Radius: 8 yards

i see u use this spell http://www.wowhead.com/?spell=54171 ( 100 yards, why ) had this spell a bug http://www.wowhead.com/?spell=53385 ?

thanks

Link to comment
Share on other sites

  • 4 weeks later...

The 8 yards are only for the damage. I have not found the exact distance, only this information:

The heal from DS is a smart heal. It targets the lowest health raid member and heals them for as much as it can. It will heal only exactly their health total and then spill over up to two times. In a raid situation that heal should be used 99%+ of the time since it only doesn't do anything if the raid has full health on all raid members. The range of the heal is over 40 yards, though I didn't exhaustively test the maximum range.

http://elitistjerks.com/f76/t71197-glyph_divine_storm/

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use