aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/updates/world/2013_11_03_00_world_spell_script_names_434.sql2
-rw-r--r--src/server/scripts/Spells/spell_warlock.cpp40
2 files changed, 42 insertions, 0 deletions
diff --git a/sql/updates/world/2013_11_03_00_world_spell_script_names_434.sql b/sql/updates/world/2013_11_03_00_world_spell_script_names_434.sql
new file mode 100644
index 00000000000..5a3a4b29db5
--- /dev/null
+++ b/sql/updates/world/2013_11_03_00_world_spell_script_names_434.sql
@@ -0,0 +1,2 @@
+DELETE FROM `spell_script_names` WHERE `spell_id`=77799; -- Fel Flame
+INSERT INTO `spell_script_names`(`spell_id`, `ScriptName`) VALUES (77799, "spell_warl_fel_flame"); \ No newline at end of file
diff --git a/src/server/scripts/Spells/spell_warlock.cpp b/src/server/scripts/Spells/spell_warlock.cpp
index bae21d0baea..7e0de4ce506 100644
--- a/src/server/scripts/Spells/spell_warlock.cpp
+++ b/src/server/scripts/Spells/spell_warlock.cpp
@@ -1431,6 +1431,45 @@ class spell_warl_unstable_affliction : public SpellScriptLoader
}
};
+// 77799 - Fel Flame
+// Updated 4.3.4
+class spell_warl_fel_flame : public SpellScriptLoader
+{
+public:
+ spell_warl_fel_flame() : SpellScriptLoader("spell_warl_fel_flame") { }
+
+ class spell_warl_fel_flame_SpellScript : public SpellScript
+ {
+ PrepareSpellScript(spell_warl_fel_flame_SpellScript);
+
+ bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE
+ {
+ return sSpellMgr->GetSpellInfo(SPELL_WARLOCK_IMMOLATE) && sSpellMgr->GetSpellInfo(SPELL_WARLOCK_UNSTABLE_AFFLICTION);
+ }
+
+ void ScriptEffect(SpellEffIndex /*effIndex*/)
+ {
+ uint32 bonus = GetSpellInfo()->Effects[EFFECT_1].CalcValue(GetCaster()) * IN_MILLISECONDS;
+ // Increase Immolate duration
+ if (Aura const* aura = GetHitUnit()->GetAura(SPELL_WARLOCK_IMMOLATE, GetCaster()->GetGUID()))
+ aura->SetDuration(aura->GetDuration() + bonus);
+ // Increase Unstable Affliction duration
+ if (Aura const* aura = GetHitUnit()->GetAura(SPELL_WARLOCK_UNSTABLE_AFFLICTION, GetCaster()->GetGUID()))
+ aura->SetDuration(aura->GetDuration() + bonus);
+ }
+
+ void Register() OVERRIDE
+ {
+ OnEffectHitTarget += SpellEffectFn(spell_warl_fel_flame_SpellScript::ScriptEffect, EFFECT_1, SPELL_EFFECT_SCRIPT_EFFECT);
+ }
+ };
+
+ SpellScript* GetSpellScript() const OVERRIDE
+ {
+ return new spell_warl_fel_flame_SpellScript();
+ }
+};
+
void AddSC_warlock_spell_scripts()
{
new spell_warl_aftermath();
@@ -1463,4 +1502,5 @@ void AddSC_warlock_spell_scripts()
new spell_warl_soul_swap_override();
new spell_warl_soulshatter();
new spell_warl_unstable_affliction();
+ new spell_warl_fel_flame();
}