aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2011-01-28 14:33:12 +0100
committerShauren <shauren.trinity@gmail.com>2011-01-28 14:33:12 +0100
commitcf882245883e2f1c5634345fee8403a3c891f7cc (patch)
tree49b3e474fa75b2be81b9349658fab83be723cf3a /src
parentea00b2ac10e5464e20532544a48204cc5b286b4a (diff)
Scripts/Icecrown Citadel: Implemented Pact of the Darkfallen damage scaling (Blood-Queen Lana'thel)
SQL: Renamed and split 2011_01_26_world_scriptname to meet the standards
Diffstat (limited to 'src')
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp40
1 files changed, 40 insertions, 0 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 ab3b19c14f8..ee8f837c168 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
@@ -54,6 +54,7 @@ enum Spells
SPELL_DELIRIOUS_SLASH = 71623,
SPELL_PACT_OF_THE_DARKFALLEN_TARGET = 71336,
SPELL_PACT_OF_THE_DARKFALLEN = 71340,
+ SPELL_PACT_OF_THE_DARKFALLEN_DAMAGE = 71341,
SPELL_SWARMING_SHADOWS = 71264,
SPELL_TWILIGHT_BLOODBOLT_TARGET = 71445,
SPELL_TWILIGHT_BLOODBOLT = 71446,
@@ -617,6 +618,44 @@ class spell_blood_queen_pact_of_the_darkfallen : public SpellScriptLoader
}
};
+class spell_blood_queen_pact_of_the_darkfallen_dmg : public SpellScriptLoader
+{
+ public:
+ spell_blood_queen_pact_of_the_darkfallen_dmg() : SpellScriptLoader("spell_blood_queen_pact_of_the_darkfallen_dmg") { }
+
+ class spell_blood_queen_pact_of_the_darkfallen_dmg_AuraScript : public AuraScript
+ {
+ PrepareAuraScript(spell_blood_queen_pact_of_the_darkfallen_dmg_AuraScript);
+
+ bool Validate(SpellEntry const* /*spell*/)
+ {
+ if (!sSpellStore.LookupEntry(SPELL_PACT_OF_THE_DARKFALLEN_DAMAGE))
+ return false;
+ return true;
+ }
+
+ // this is an additional effect to be executed
+ void PeriodicTick(AuraEffect const* aurEff)
+ {
+ SpellEntry const* damageSpell = sSpellStore.LookupEntry(SPELL_PACT_OF_THE_DARKFALLEN_DAMAGE);
+ int32 damage = SpellMgr::CalculateSpellEffectAmount(damageSpell, EFFECT_0);
+ float multiplier = 0.3375f + 0.1f * uint32(aurEff->GetTickNumber()/10); // do not convert to 0.01f - we need tick number/10 as INT (damage increases every 10 ticks)
+ damage = uint32(damage * multiplier);
+ GetTarget()->CastCustomSpell(SPELL_PACT_OF_THE_DARKFALLEN_DAMAGE, SPELLVALUE_BASE_POINT0, damage, GetTarget(), true);
+ }
+
+ void Register()
+ {
+ OnEffectPeriodic += AuraEffectPeriodicFn(spell_blood_queen_pact_of_the_darkfallen_dmg_AuraScript::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL);
+ }
+ };
+
+ AuraScript* GetAuraScript() const
+ {
+ return new spell_blood_queen_pact_of_the_darkfallen_dmg_AuraScript();
+ }
+};
+
class achievement_once_bitten_twice_shy_n : public AchievementCriteriaScript
{
public:
@@ -656,6 +695,7 @@ void AddSC_boss_blood_queen_lana_thel()
new spell_blood_queen_frenzied_bloodthirst();
new spell_blood_queen_bloodbolt();
new spell_blood_queen_pact_of_the_darkfallen();
+ new spell_blood_queen_pact_of_the_darkfallen_dmg();
new achievement_once_bitten_twice_shy_n();
new achievement_once_bitten_twice_shy_v();
}