Jump to content

Recommended Posts

Posted

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

When caster's Flame Shock is dispelled their spell casting speed is increased by 10/20/30% for 6 sec if they have Lava Flows talent.

For which repository revision was the patch created?

revision 8918

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/viewtopic.php?id=11317

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

by myself

Unit.cpp, RemoveSingleAuraDueToSpellByDispel()

           // backfire damage and silence
           dispeler->CastCustomSpell(dispeler, 31117, &damage, NULL, NULL, true, NULL, NULL,casterGUID);
       }
   }
+    // Lava Flows
+    else if ( spellEntry->SpellFamilyName == SPELLFAMILY_SHAMAN && ( spellEntry->SpellFamilyFlags & UI64LIT(0x10000000) ) )
+    {        
+        Unit* caster = NULL;
+        uint32 triggeredSpell = 0;
+
+        if ( Aura* dotAura = GetAura( SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_SHAMAN, UI64LIT(0x10000000), 0x00000000, casterGUID ) )
+            caster = dotAura->GetCaster();
+
+        if ( caster && !caster->isDead() )
+        {
+            Unit::AuraList const& auras = caster->GetAurasByType(SPELL_AURA_DUMMY);
+            
+            for ( Unit::AuraList::const_iterator i = auras.begin(); i != auras.end(); i++ )
+            {
+                switch((*i)->GetId())
+                {
+                    case 51480: 
+                    {
+                        triggeredSpell = 64694;
+                        break;
+                    }
+                    case 51481:
+                    {
+                        triggeredSpell = 65263;
+                        break;
+                    }
+                    case 51482:
+                    {
+                        triggeredSpell = 65264;
+                        break;
+                    }
+                    default: 
+                        continue;
+                }
+                break;
+            }
+        }
+        // Remove spell auras from stack
+        RemoveSingleSpellAurasByCasterSpell(spellId, casterGUID, AURA_REMOVE_BY_DISPEL);
+
+        // Haste
+        if( triggeredSpell )
+            caster->CastSpell( caster, triggeredSpell, true );                    
+
+    }
   else
       RemoveSingleSpellAurasByCasterSpell(spellId, casterGUID, AURA_REMOVE_BY_DISPEL);
}

  • 39 years later...
Posted

There should be a diff:

diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index 701e5ec..d5c17fa 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -3962,6 +3962,50 @@ void Unit::RemoveSingleAuraDueToSpellByDispel(uint32 spellId, uint64 casterGUID,
            dispeler->CastCustomSpell(dispeler, 31117, &damage, NULL, NULL, true, NULL, NULL,casterGUID);
        }
    }
+    // Lava Flows
+    else if (spellEntry->SpellFamilyName == SPELLFAMILY_SHAMAN && (spellEntry->SpellFamilyFlags & UI64LIT(0x10000000)))
+    {
+        Unit* caster = NULL;
+        uint32 triggeredSpell = 0;
+ 
+        if (Aura* dotAura = GetAura(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_SHAMAN, UI64LIT(0x10000000), 0x00000000, casterGUID))
+            caster = dotAura->GetCaster();
+ 
+        if (caster && !caster->isDead())
+        {
+            Unit::AuraList const& auras = caster->GetAurasByType(SPELL_AURA_DUMMY);	
+            for (Unit::AuraList::const_iterator i = auras.begin(); i != auras.end(); i++)
+            {
+                switch((*i)->GetId())
+                {
+                    case 51480: 
+                    {
+                        triggeredSpell = 64694;
+                        break;
+                    }
+                    case 51481:
+                    {
+                        triggeredSpell = 65263;
+                        break;
+                    }
+                    case 51482:
+                    {
+                        triggeredSpell = 65264;
+                        break;
+                    }
+                    default: 
+                        continue;
+                }
+                break;
+            }
+        }
+        // Remove spell auras from stack
+        RemoveSingleSpellAurasByCasterSpell(spellId, casterGUID, AURA_REMOVE_BY_DISPEL);
+ 
+        // Haste
+        if (triggeredSpell)
+            caster->CastSpell( caster, triggeredSpell, true);	                
+    }
    else
        RemoveSingleSpellAurasByCasterSpell(spellId, casterGUID, AURA_REMOVE_BY_DISPEL);
}

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