From 8ad4f0f10b62492ec204cae8c51b43ea75fc91c4 Mon Sep 17 00:00:00 2001 From: VladimirMangos Date: Sat, 3 Oct 2009 07:12:36 +0400 Subject: [PATCH] Restore spell 53563 work at 3.2.x --- sql/mangos_spell_check.sql | 3 ++- src/game/SpellAuras.cpp | 19 +++++-------------- src/game/Unit.cpp | 2 +- 3 files changed, 8 insertions(+), 16 deletions(-) diff --git a/sql/mangos_spell_check.sql b/sql/mangos_spell_check.sql index 0c9a97933..aa401c50f 100644 --- a/sql/mangos_spell_check.sql +++ b/sql/mangos_spell_check.sql @@ -413,4 +413,5 @@ INSERT INTO spell_check (spellid,SpellFamilyName,SpellFamilyMaskA,SpellFamilyMas /* some random spells from not proccessed files sorted by spell ids */ /*id fm familyMaskA fmMaskB icon vis cat eff aur ef name code */ -(53563,-1, -1, -1, -1, -1, -1, -1, 4,-1,'Beacon of Light', 'Aura::HandleAuraDummy'); /* will outdated in 3.2.x */ +(53563,-1, -1, -1, -1, -1, -1, -1, 23,-1,'Beacon of Light', 'Aura::HandlePeriodicTriggerSpell'), +(53563,-1, -1, -1, -1, -1, -1, -1, 23,-1,'Beacon of Light', 'Unit::HandleDummyAuraProc'); diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index b6618c936..288abc0d5 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -2145,6 +2145,11 @@ void Aura::TriggerSpell() case 33525: target->CastSpell(target, trigger_spell_id, true); return; + // Beacon of Light + case 53563: + // original caster must be target (beacon) + m_target->CastSpell(m_target,trigger_spell_id,true,NULL,this,m_target->GetGUID()); + return; } } @@ -2451,9 +2456,7 @@ void Aura::HandleAuraDummy(bool apply, bool Real) break; } case SPELLFAMILY_MAGE: - { break; - } case SPELLFAMILY_PRIEST: { // Pain and Suffering @@ -2477,19 +2480,7 @@ void Aura::HandleAuraDummy(bool apply, bool Real) break; } case SPELLFAMILY_PALADIN: - { - // Beacon of Light - if (GetId() == 53563) - { - if(apply) - // original caster must be target (beacon) - m_target->CastSpell(m_target,53651,true,NULL,this,m_target->GetGUID()); - else - m_target->RemoveAurasByCasterSpell(53651,m_target->GetGUID()); - return; - } break; - } case SPELLFAMILY_DRUID: { switch(GetId()) diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 7e30563b0..3543837a4 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -5850,7 +5850,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu // find caster main aura at beacon Aura* dummy = NULL; - Unit::AuraList const& baa = beacon->GetAurasByType(SPELL_AURA_DUMMY); + Unit::AuraList const& baa = beacon->GetAurasByType(SPELL_AURA_PERIODIC_TRIGGER_SPELL); for(Unit::AuraList::const_iterator i = baa.begin(); i != baa.end(); ++i) { if ((*i)->GetId() == 53563 && (*i)->GetCasterGUID() == pVictim->GetGUID())