Jump to content

[patch][6191] Dark Pact (spell_effect_mana_drain)


Auntie Mangos
 Share

Recommended Posts

What bug does the patch fix?

Dark Pact and all other spells with SPELL_EFFECT_MANA_DRAIN gets no spell damage. Calculation is present in function Unit::SpellDamageBonus(), but this function is not called for this spells at all. And also there is no sent information about gains in combat log.

For which SubVersion revision was the patch created?

6084

Is there a thread in the bug report section?

http://getmangos.eu/community/viewtopic.p...mp;hl=dark+pact

Who has been writing this patch?

Ultron

Index: game/SpellEffects.cpp
===================================================================
--- game/SpellEffects.cpp                (revision 6084)
+++ game/SpellEffects.cpp                (working copy)
@@ -1958,7 +1958,10 @@

                int32 new_damage;

-                // resilience reduce mana draining effect (added in 2.4)
+                //add spell damage bonus
+                damage=m_caster->SpellDamageBonus(unitTarget,m_spellInfo,uint32(damage),SPELL_DIRECT_DAMAGE);
+                
+                // resilience reduce mana draining effect (added in 2.4)
                uint32 power = damage;
                if ( drain_power == POWER_MANA && unitTarget->GetTypeId() == TYPEID_PLAYER )
                                power -= ((Player*)unitTarget)->GetDotDamageReduction(damage);
@@ -1980,6 +1983,8 @@
                                                modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_MULTIPLE_VALUE, manaMultiplier);

                                m_caster->ModifyPower(POWER_MANA,uint32(new_damage*manaMultiplier));
+                                //send log
+                                m_caster->SendEnergizeSpellLog(m_caster, m_spellInfo->Id,uint32(new_damage*manaMultiplier),POWER_MANA,false);
                }
}

http://filebeam.com/0245fe6a5da32d590753f0db06cbdd74

Link to comment
Share on other sites

  • 38 years later...
Guest
This topic is now closed to further replies.
 Share

×
×
  • 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