Jump to content

[11662][Patch] Spell 37433


Guest anti-freak

Recommended Posts

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

this spell should ignore his knockback and dmg effekt if target is in water. (the lurker below: spout)

For which repository revision was the patch created?

[s1009]

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

No.

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 930ff5c..49f7fcd 100644
--- a/src/game/Spell.cpp
+++ b/src/game/Spell.cpp
@@ -3739,6 +3739,10 @@ void Spell::HandleEffects(Unit *pUnitTarget,Item *pItemTarget,GameObject *pGOTar
    itemTarget = pItemTarget;
    gameObjTarget = pGOTarget;

+    //ignore knockback from spout (the lurker below)
+    if(m_spellInfo->Id == 37433 && unitTarget && unitTarget->IsInWater())
+        return;
+
    uint8 eff = m_spellInfo->Effect[i];

    damage = int32(CalculateDamage(i, unitTarget) * DamageMultiplier);

diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp
index eb2aa20..f4c8687 100644
--- a/src/game/SpellEffects.cpp
+++ b/src/game/SpellEffects.cpp
@@ -356,6 +356,10 @@ void Spell::EffectSchoolDMG(SpellEffectIndex effect_idx)
                    case 38441:
                        damage = unitTarget->GetMaxHealth() / 2;
                        break;
+                    case 37433:
+                        if (unitTarget && unitTarget->IsInWater())
+                            return;
+                        break;
                }
                break;
            }

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...
  • 1 month later...
×
×
  • 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