diff options
author | megamage <none@none> | 2009-05-18 15:04:05 -0500 |
---|---|---|
committer | megamage <none@none> | 2009-05-18 15:04:05 -0500 |
commit | e8be2f026e59acb2a1629e4300c07cfbc9d2af89 (patch) | |
tree | 7e41896618aa3bf2a7938081f89e26ed442977da | |
parent | 609f7bd6b97875cf8fcbe38b8615908d896f3684 (diff) |
*Add some scripted spells for naxx.
--HG--
branch : trunk
-rw-r--r-- | sql/updates/3233_world_scripts_naxx.sql | 15 | ||||
-rw-r--r-- | src/game/SpellAuras.cpp | 21 | ||||
-rw-r--r-- | src/game/SpellEffects.cpp | 14 | ||||
-rw-r--r-- | src/game/SpellMgr.cpp | 4 |
4 files changed, 52 insertions, 2 deletions
diff --git a/sql/updates/3233_world_scripts_naxx.sql b/sql/updates/3233_world_scripts_naxx.sql index c809c5b280c..230ca99b867 100644 --- a/sql/updates/3233_world_scripts_naxx.sql +++ b/sql/updates/3233_world_scripts_naxx.sql @@ -5,7 +5,20 @@ INSERT INTO `spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comm (-29865, 55594, 0, 'Deathbloom'), (-55053, 55601, 0, 'Deathbloom (H)'), (-28169, 28206, 0, 'Mutating Injection - Mutagen Explosion'), -(-28169, 28240, 0, 'Mutating Injection - Poison Cloud'); +(-28169, 28240, 0, 'Mutating Injection - Poison Cloud'), +( 28059,-28084, 1, 'Positive Charge - Negative Charge'), +( 39088,-39091, 1, 'Positive Charge - Negative Charge'), +(-28059,-29659, 0, 'Positive Charge'), +(-39088,-29659, 0, 'Positive Charge'), +( 28062,-29659, 0, 'Positive Charge'), +( 39090,-29659, 0, 'Positive Charge'), +( 28084,-28059, 1, 'Negative Charge - Positive Charge'), +( 39091,-39088, 1, 'Negative Charge - Positive Charge'), +(-28084,-29660, 0, 'Negative Charge'), +(-39091,-29660, 0, 'Negative Charge'), +( 28085,-29660, 0, 'Negative Charge'), +( 39093,-29660, 0, 'Negative Charge'); + UPDATE creature_template SET scriptname = 'boss_grobbulus' WHERE entry = 15931; update creature_template set scriptname='mob_gothik_minion' where entry in (16124,16125,16126,16127,16148,16149,16150); diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index 19d4b43bb38..124fdd9543b 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -2346,6 +2346,27 @@ void AuraEffect::HandleAuraDummy(bool apply, bool Real, bool changeAmount) if(caster) caster->CastSpell(caster,13138,true,NULL,this); return; + case 28832: // Mark of Korth'azz + case 28833: // Mark of Blaumeux + case 28834: // Mark of Rivendare + case 28835: // Mark of Zeliek + { + int8 stack = GetParentAura()->GetStackAmount(); + int32 damage; + switch(stack) + { + case 1: return; + case 2: damage = 500; break; + case 3: damage = 1000; break; + case 4: damage = 1500; break; + case 5: damage = 4000; break; + case 6: damage = 12000; break; + default:damage = 20000 + 1000 * (stack - 7); break; + } + if(caster) + caster->CastCustomSpell(28836, SPELLVALUE_BASE_POINT0, damage, m_target); + return; + } case 34026: // kill command { Unit * pet = m_target->GetGuardianPet(); diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index 47ef23ad855..c28e992adde 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -337,6 +337,17 @@ void Spell::SpellDamageSchoolDmg(uint32 effect_idx) switch(m_spellInfo->Id) // better way to check unknown { + // Positive/Negative Charge + case 28062: + case 39090: + case 28085: + case 39093: + if(m_triggeredByAuraSpell && unitTarget->HasAura(m_triggeredByAuraSpell->Id)) + { + damage = 0; + m_caster->CastSpell(m_caster, (m_spellInfo->Id == 28062 || m_spellInfo->Id == 39090) ? 29659 : 29660, true); + } + break; // percent from health with min case 25599: // Thundercrash { @@ -1011,6 +1022,9 @@ void Spell::EffectDummy(uint32 i) m_caster->CastSpell(unitTarget,29294,true); return; } + // Polarity Shift + case 28089: spell_id = roll_chance_i(50) ? 28059 : 28084; break; + case 39096: spell_id = roll_chance_i(50) ? 39088 : 39091; break; case 29200: // Purify Helboar Meat { if( m_caster->GetTypeId() != TYPEID_PLAYER ) diff --git a/src/game/SpellMgr.cpp b/src/game/SpellMgr.cpp index 5de2f843c87..4c83d286620 100644 --- a/src/game/SpellMgr.cpp +++ b/src/game/SpellMgr.cpp @@ -3198,7 +3198,9 @@ void SpellMgr::LoadSpellCustomAttr() case 45150: // Meteor Slash mSpellCustomAttr[i] |= SPELL_ATTR_CU_SHARE_DAMAGE; break; - case 27820: + case 27820: // Mana Detonation + case 28062: case 39090: // Positive/Negative Charge + case 28085: case 39093: mSpellCustomAttr[i] |= SPELL_ATTR_CU_EXCLUDE_SELF; break; case 44978: case 45001: case 45002: // Wild Magic |