diff options
author | maximius <none@none> | 2009-10-15 00:10:54 -0700 |
---|---|---|
committer | maximius <none@none> | 2009-10-15 00:10:54 -0700 |
commit | 47079eb853337bf11fe2dbf1007f07b3048566e7 (patch) | |
tree | f333d989fcd9c86e127cfd3c96070849a928ec90 /src | |
parent | ae3a82feed6c46a87c0c36f5572352131e9d1864 (diff) |
*Improved Fire Nova Totem & Earthen Power, patch converted by QuaLiT1
--HG--
branch : trunk
Diffstat (limited to 'src')
-rw-r--r-- | src/game/SpellAuras.cpp | 20 | ||||
-rw-r--r-- | src/game/Unit.cpp | 9 |
2 files changed, 29 insertions, 0 deletions
diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index c663061ae74..f1f5b4f21f4 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -6271,6 +6271,26 @@ void AuraEffect::PeriodicTick() } case SPELL_AURA_PERIODIC_TRIGGER_SPELL: { + Unit *pCaster = GetCaster(); + if (!pCaster) + return; + + if (pCaster->GetTypeId() == TYPEID_UNIT && ((Creature*)pCaster)->isTotem() && ((Totem*)pCaster)->GetTotemType() != TOTEM_STATUE) + { + uint32 procAttacker = PROC_FLAG_SUCCESSFUL_NEGATIVE_SPELL_HIT; // | PROC_FLAG_SUCCESSFUL_HARMFUL_SPELL_HIT; + uint32 procVictim = PROC_FLAG_SUCCESSFUL_AOE_SPELL_HIT; // | PROC_FLAG_TAKEN_HARMFUL_SPELL_HIT; + SpellEntry const *spellProto = GetSpellProto(); + + if (spellProto->SpellFamilyName == SPELLFAMILY_GENERIC) // SPELLFAMILY_GENERIC proc by triggered spell + { + uint32 trigger_spell_id = spellProto->EffectTriggerSpell[m_effIndex]; + SpellEntry const *triggeredSpellInfo = sSpellStore.LookupEntry(trigger_spell_id); + ((Totem*)pCaster)->GetOwner()->ProcDamageAndSpell(pCaster, procAttacker, procVictim, PROC_EX_NORMAL_HIT, 0, BASE_ATTACK, triggeredSpellInfo); + } + else + ((Totem*)pCaster)->GetOwner()->ProcDamageAndSpell(pCaster, procAttacker, procVictim, PROC_EX_NORMAL_HIT, 0, BASE_ATTACK, spellProto); + } + TriggerSpell(); break; } diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index af70169ee39..17b9a6dce58 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -5815,6 +5815,15 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger triggered_spell_id = 28810; break; } + // Improved Fire Nova (Rank 2) + case 16544: + triggered_spell_id = 51880; + break; + // Earthen Power (Rank 1, 2) + case 51523: + case 51524: + triggered_spell_id = 63532; + break; } break; } |