diff options
author | silinoron <none@none> | 2010-09-05 14:59:46 -0700 |
---|---|---|
committer | silinoron <none@none> | 2010-09-05 14:59:46 -0700 |
commit | 5e95be0c33d25bb9832d20e724f7c7279d1e82ca (patch) | |
tree | 45ac5d6dd92be7a2dfa1c3bb9fc200ebf8d626b3 | |
parent | 4f112d6a9d75130558484284a0553575ac8048c7 (diff) |
Fix Glyph of Totem of Wrath.
Fixes issue #3743
Patch by dr.tenma.
--HG--
branch : trunk
-rw-r--r-- | sql/base/world_database.sql | 2 | ||||
-rw-r--r-- | sql/updates/9791_world_spell_group.sql | 1 | ||||
-rw-r--r-- | sql/updates/9791_world_spell_proc_event.sql | 3 | ||||
-rw-r--r-- | src/server/game/Entities/Unit/Unit.cpp | 32 |
4 files changed, 37 insertions, 1 deletions
diff --git a/sql/base/world_database.sql b/sql/base/world_database.sql index bff37f7818c..f74ef0eeb10 100644 --- a/sql/base/world_database.sql +++ b/sql/base/world_database.sql @@ -17597,7 +17597,6 @@ INSERT INTO `spell_group` (`id`, `spell_id`) VALUES -- Increased Spell Power Buff (1044,54646), -- Focus Magic (1045,52109), -- Flametongue Totem -(1046,63283), -- Totem of Wrath (1046,57658), -- Totem of Wrath (1046,57660), -- Totem of Wrath (1046,57662), -- Totem of Wrath @@ -19105,6 +19104,7 @@ INSERT INTO `spell_proc_event` (`entry`,`SchoolMask`,`SpellFamilyName`,`SpellFam ( 63108, 0x00, 5, 0x00000002, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Siphon Life ( 63158, 0x00, 5, 0x00000001, 0x000000C0, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Decimation ( 63156, 0x00, 5, 0x00000001, 0x000000C0, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Decimation +( 63280, 0x00, 11, 0x20000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Glyph ofTotem of Wrath ( 64343, 0x00, 3, 0x00000002, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Impact ( 64976, 0x00, 4, 0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Juggernaut ( 64914, 0x00, 8, 0x00010000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 0), -- Item - Rogue T8 2P Bonus diff --git a/sql/updates/9791_world_spell_group.sql b/sql/updates/9791_world_spell_group.sql new file mode 100644 index 00000000000..19d113a7ab0 --- /dev/null +++ b/sql/updates/9791_world_spell_group.sql @@ -0,0 +1 @@ +DELETE FROM `spell_group` WHERE `spell_id` IN ('63283'); diff --git a/sql/updates/9791_world_spell_proc_event.sql b/sql/updates/9791_world_spell_proc_event.sql new file mode 100644 index 00000000000..c30c6c7974e --- /dev/null +++ b/sql/updates/9791_world_spell_proc_event.sql @@ -0,0 +1,3 @@ +DELETE FROM `spell_proc_event` WHERE `entry`=63280; +INSERT INTO `spell_proc_event` (`entry`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`procFlags`,`procEx`,`ppmRate`,`CustomChance`,`Cooldown`) VALUES +(63280,0x00,11,0x20000000,0x00000000,0x00000000,0x00000000,0x00000000,0,0,0); -- Glyph ofTotem of Wrath diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index b947aca725e..40b405ccacb 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -7416,6 +7416,38 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger } return false; } + case 63280: // Glyph of Totem of Wrath + { + if (procSpell->SpellIconID != 2019) + return false; + + AuraEffect * aurEffA = NULL; + AuraEffectList const& auras = GetAuraEffectsByType(SPELL_AURA_MOD_DAMAGE_DONE); + for (AuraEffectList::const_iterator i = auras.begin(); i != auras.end(); ++i) + { + SpellEntry const *spell = (*i)->GetSpellProto(); + if (spell->SpellFamilyName == uint32(SPELLFAMILY_SHAMAN) && spell->SpellFamilyFlags.HasFlag(0, 0x02000000, 0)) + { + if ((*i)->GetCasterGUID() != GetGUID()) + continue; + if (spell->Id == 63283) + continue; + aurEffA = (*i); + break; + } + } + if (aurEffA) + { + int32 bp0 = 0, bp1 = 0; + bp0 = aurEffA->GetAmount() * triggerAmount / 100; + if (AuraEffect * aurEffB = aurEffA->GetBase()->GetEffect(EFFECT_1)) + bp1 = aurEffB->GetAmount() * triggerAmount / 100; + CastCustomSpell(this, 63283, &bp0, &bp1, NULL, true, NULL, triggeredByAura); + return true; + } + return false; + } + break; } // Frozen Power if (dummySpell->SpellIconID == 3780) |