Jump to content

[9457] Gift of the Naaru

Auntie Mangos

Recommended Posts

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

Added scaling with attack power or spellpower.

For which repository revision was the patch created?


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


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


Link to patch:


Link to comment
Share on other sites

  • 39 years later...

maybe something like this:

    // Gift of the Naaru
   if (m_spellProto->SpellFamilyFlags2 & 0x80000000)
       Unit *caster = GetCaster();
       if (!caster)

       SpellBonusEntry const* bonus = sSpellMgr.GetSpellBonusData(m_spellProto->Id);
       if (bonus)
           int32 ap = int32(bonus->ap_bonus * caster->GetTotalAttackPowerValue(BASE_ATTACK));
           int32 sp = int32(bonus->dot_bonus * (caster->SpellBaseDamageBonus(GetSpellSchoolMask(m_spellProto))
                    + caster->SpellBaseDamageBonusForVictim(GetSpellSchoolMask(m_spellProto), m_target)));
           m_modifier.m_amount += ap > sp ? ap : sp;

Link to comment
Share on other sites

  • 2 months later...

link in first post is expired. Here the patch

diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp
index 3a19b61..90bd416 100644
--- a/src/game/SpellAuras.cpp
+++ b/src/game/SpellAuras.cpp
@@ -4651,6 +4651,20 @@ void Aura::HandleAuraPeriodicDummy(bool apply, bool Real)
void Aura::HandlePeriodicHeal(bool apply, bool /*Real*/)
    m_isPeriodic = apply;
+    // Gift of the Naaru
+    if ((m_spellProto->SpellFamilyFlags2 & UI64LIT(0x80000000)) && m_spellProto->SpellVisual[0] == 7625)
+    {
+        Unit *caster = GetCaster();
+        if (!caster)
+            return;
+        int32 ap = int32 (0.22f * caster->GetTotalAttackPowerValue(BASE_ATTACK));
+        int32 holy = caster->SpellBaseDamageBonus(GetSpellSchoolMask(m_spellProto))
+                   + caster->SpellBaseDamageBonusForVictim(GetSpellSchoolMask(m_spellProto), m_target);
+        holy = int32(holy * 377 / 1000);
+        m_modifier.m_amount += ap > holy ? ap : holy;
+    }

void Aura::HandlePeriodicDamage(bool apply, bool Real)

Link to comment
Share on other sites

any possibility to use spell_bonus_data table instead hardcoded?

1) if selected max from 2 cases so only can be coded.

2) spell_bonus_data only form normal implicit spell/attack power coefs, because it applied to final damage

fir scale bonuses described in spell itsefl need use explicit code because this part of original spell damage and then must be affected later percent and flag bonuses

Link to comment
Share on other sites

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