Jump to content

[fix] applying bonus damage from spell power to Drain Soul


Guest AuntieMangos

Recommended Posts

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

this patch fixes drain soul bonus damage calculation (for "execute" case)

For which repository revision was the patch created?

[10075]

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

bug explained here (not in first post)

http://getmangos.eu/community/showthread.php?13687-bug-Drain-soul

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

me

diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp
index 8ff7d2f..212050d 100644
--- a/src/game/SpellAuras.cpp
+++ b/src/game/SpellAuras.cpp
@@ -4957,9 +4957,11 @@ void Aura::HandlePeriodicDamage(bool apply, bool Real)
      }
      case SPELLFAMILY_WARLOCK:
      {
-        // Drain Soul
+        // Drain Soul $SP*0.429 per tick
        if (spellProto->SpellFamilyFlags & UI64LIT(0x0000000000004000))
        {
+          m_modifier.m_amount += int32(((Player*)caster)->GetBaseSpellPowerBonus() * 42.90 / 100);
+
          if (target->GetHealth() * 100 / target->GetMaxHealth() <= 25)
            m_modifier.m_amount *= 4;
        }

and SQL fix

DELETE FROM spell_bonus_data WHERE entry IN (1120);
INSERT INTO spell_bonus_data VALUES
(1120, 0, 0, 0, 'Warlock - Drain Soul');

Link to comment
Share on other sites

  • 40 years later...
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