aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/Northrend
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/scripts/Northrend')
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp38
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp16
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp18
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp37
-rw-r--r--src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp2
5 files changed, 99 insertions, 12 deletions
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
index c8caa3976e4..ab0c44aa6d0 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
@@ -46,6 +46,7 @@ enum Spells
SPELL_FRENZIED_BLOODTHIRST_VISUAL = 71949,
SPELL_VAMPIRIC_BITE = 71726,
SPELL_ESSENCE_OF_THE_BLOOD_QUEEN_PLR = 70879,
+ SPELL_ESSENCE_OF_THE_BLOOD_QUEEN_HEAL = 70872,
SPELL_FRENZIED_BLOODTHIRST = 70877,
SPELL_UNCONTROLLABLE_FRENZY = 70923,
SPELL_PRESENCE_OF_THE_DARKFALLEN = 71952,
@@ -698,6 +699,42 @@ class spell_blood_queen_bloodbolt : public SpellScriptLoader
}
};
+// 70871 - Essence of the Blood Queen
+class spell_blood_queen_essence_of_the_blood_queen : public SpellScriptLoader
+{
+ public:
+ spell_blood_queen_essence_of_the_blood_queen() : SpellScriptLoader("spell_blood_queen_essence_of_the_blood_queen") { }
+
+ class spell_blood_queen_essence_of_the_blood_queen_AuraScript : public AuraScript
+ {
+ PrepareAuraScript(spell_blood_queen_essence_of_the_blood_queen_AuraScript);
+
+ bool Validate(SpellInfo const* /*spellInfo*/)
+ {
+ if (!sSpellMgr->GetSpellInfo(SPELL_ESSENCE_OF_THE_BLOOD_QUEEN_HEAL))
+ return false;
+ return true;
+ }
+
+ void OnProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
+ {
+ PreventDefaultAction();
+ int32 heal = CalculatePct(int32(eventInfo.GetDamageInfo()->GetDamage()), aurEff->GetAmount());
+ GetTarget()->CastCustomSpell(SPELL_ESSENCE_OF_THE_BLOOD_QUEEN_HEAL, SPELLVALUE_BASE_POINT0, heal, GetTarget(), TRIGGERED_FULL_MASK, NULL, aurEff);
+ }
+
+ void Register()
+ {
+ OnEffectProc += AuraEffectProcFn(spell_blood_queen_essence_of_the_blood_queen_AuraScript::OnProc, EFFECT_1, SPELL_AURA_DUMMY);
+ }
+ };
+
+ AuraScript* GetAuraScript() const
+ {
+ return new spell_blood_queen_essence_of_the_blood_queen_AuraScript();
+ }
+};
+
class spell_blood_queen_pact_of_the_darkfallen : public SpellScriptLoader
{
public:
@@ -849,6 +886,7 @@ void AddSC_boss_blood_queen_lana_thel()
new spell_blood_queen_vampiric_bite();
new spell_blood_queen_frenzied_bloodthirst();
new spell_blood_queen_bloodbolt();
+ new spell_blood_queen_essence_of_the_blood_queen();
new spell_blood_queen_pact_of_the_darkfallen();
new spell_blood_queen_pact_of_the_darkfallen_dmg();
new spell_blood_queen_pact_of_the_darkfallen_dmg_target();
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp
index ce1166663f3..59d69d658cc 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp
@@ -415,6 +415,13 @@ class boss_deathbringer_saurfang : public CreatureScript
}
}
+ void SpellHit(Unit* /*caster*/, SpellInfo const* spell)
+ {
+ if (spell->Id == SPELL_BLOOD_LINK_POWER)
+ if (Aura* bloodPower = me->GetAura(SPELL_BLOOD_POWER))
+ bloodPower->RecalculateAmountOfEffects();
+ }
+
void UpdateAI(uint32 const diff)
{
if (!UpdateVictim() && !(events.GetPhaseMask() & PHASE_INTRO_MASK))
@@ -1004,8 +1011,6 @@ class spell_deathbringer_blood_link : public SpellScriptLoader
void HandleDummy(SpellEffIndex /*effIndex*/)
{
GetHitUnit()->CastCustomSpell(SPELL_BLOOD_LINK_POWER, SPELLVALUE_BASE_POINT0, GetEffectValue(), GetHitUnit(), true);
- if (Aura* bloodPower = GetHitUnit()->GetAura(SPELL_BLOOD_POWER))
- bloodPower->RecalculateAmountOfEffects();
PreventHitDefaultEffect(EFFECT_0);
}
@@ -1093,13 +1098,6 @@ class spell_deathbringer_blood_power : public SpellScriptLoader
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_deathbringer_blood_power_AuraScript::RecalculateHook, EFFECT_0, SPELL_AURA_MOD_SCALE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_deathbringer_blood_power_AuraScript::RecalculateHook, EFFECT_1, SPELL_AURA_MOD_DAMAGE_PERCENT_DONE);
}
-
- bool Load()
- {
- if (GetUnitOwner()->getPowerType() != POWER_ENERGY)
- return false;
- return true;
- }
};
SpellScript* GetSpellScript() const
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
index 4c18821d2f7..e3ab6e0941f 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
@@ -53,7 +53,7 @@ enum Spells
SPELL_COLDFLAME_SUMMON = 69147,
};
-uint32 const boneSpikeSummonId[3] = {69062, 72669, 72670};
+uint32 const BoneSpikeSummonId[3] = {69062, 72669, 72670};
enum Events
{
@@ -514,6 +514,20 @@ class spell_marrowgar_bone_spike_graveyard : public SpellScriptLoader
{
PrepareSpellScript(spell_marrowgar_bone_spike_graveyard_SpellScript);
+ bool Validate(SpellInfo const* /*spell*/)
+ {
+ for (uint32 i = 0; i < 3; ++i)
+ if (!sSpellMgr->GetSpellInfo(BoneSpikeSummonId[i]))
+ return false;
+
+ return true;
+ }
+
+ bool Load()
+ {
+ return GetCaster()->GetTypeId() == TYPEID_UNIT && GetCaster()->IsAIEnabled;
+ }
+
SpellCastResult CheckCast()
{
return GetCaster()->GetAI()->SelectTarget(SELECT_TARGET_TOPAGGRO, 1, 0.0f, true, -SPELL_IMPALED) ? SPELL_CAST_OK : SPELL_FAILED_NO_VALID_TARGETS;
@@ -535,7 +549,7 @@ class spell_marrowgar_bone_spike_graveyard : public SpellScriptLoader
break;
didHit = true;
- target->CastCustomSpell(boneSpikeSummonId[i], SPELLVALUE_BASE_POINT0, 0, target, true);
+ target->CastCustomSpell(BoneSpikeSummonId[i], SPELLVALUE_BASE_POINT0, 0, target, true);
}
if (didHit)
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp
index 962e12a2461..2dd4323ad3b 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp
@@ -145,6 +145,7 @@ enum Spells
SPELL_RESTORE_SOUL = 72595,
SPELL_RESTORE_SOULS = 73650, // Heroic
SPELL_DARK_HUNGER = 69383, // Passive proc healing
+ SPELL_DARK_HUNGER_HEAL = 69384,
SPELL_DESTROY_SOUL = 74086, // Used when Terenas Menethil dies
SPELL_SOUL_RIP = 69397, // Deals increasing damage
SPELL_SOUL_RIP_DAMAGE = 69398,
@@ -2989,6 +2990,41 @@ class spell_the_lich_king_restore_soul : public SpellScriptLoader
}
};
+class spell_the_lich_king_dark_hunger : public SpellScriptLoader
+{
+ public:
+ spell_the_lich_king_dark_hunger() : SpellScriptLoader("spell_the_lich_king_dark_hunger") { }
+
+ class spell_the_lich_king_dark_hunger_AuraScript : public AuraScript
+ {
+ PrepareAuraScript(spell_the_lich_king_dark_hunger_AuraScript);
+
+ bool Validate(SpellInfo const* /*spellInfo*/)
+ {
+ if (!sSpellMgr->GetSpellInfo(SPELL_DARK_HUNGER_HEAL))
+ return false;
+ return true;
+ }
+
+ void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
+ {
+ PreventDefaultAction();
+ int32 heal = int32(eventInfo.GetDamageInfo()->GetDamage() / 2);
+ GetTarget()->CastCustomSpell(SPELL_DARK_HUNGER_HEAL, SPELLVALUE_BASE_POINT0, heal, GetTarget(), true, NULL, aurEff);
+ }
+
+ void Register()
+ {
+ OnEffectProc += AuraEffectProcFn(spell_the_lich_king_dark_hunger_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
+ }
+ };
+
+ AuraScript* GetAuraScript() const
+ {
+ return new spell_the_lich_king_dark_hunger_AuraScript();
+ }
+};
+
class spell_the_lich_king_in_frostmourne_room : public SpellScriptLoader
{
public:
@@ -3234,6 +3270,7 @@ void AddSC_boss_the_lich_king()
new spell_the_lich_king_lights_favor();
new spell_the_lich_king_soul_rip();
new spell_the_lich_king_restore_soul();
+ new spell_the_lich_king_dark_hunger();
new spell_the_lich_king_in_frostmourne_room();
new spell_the_lich_king_summon_spirit_bomb();
new spell_the_lich_king_trigger_vile_spirit();
diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp
index 1f96848fa0a..13a4fe23690 100644
--- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp
+++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp
@@ -343,7 +343,7 @@ class boss_algalon_the_observer : public CreatureScript
DoCast(me, SPELL_RIDE_THE_LIGHTNING, true);
me->GetMotionMaster()->MovePoint(POINT_ALGALON_LAND, AlgalonLandPos);
me->SetHomePosition(AlgalonLandPos);
- Movement::MoveSplineInit init(*me);
+ Movement::MoveSplineInit init(me);
init.MoveTo(AlgalonLandPos.GetPositionX(), AlgalonLandPos.GetPositionY(), AlgalonLandPos.GetPositionZ());
init.SetOrientationFixed(true);
init.Launch();