diff options
| author | ariel- <ariel-@users.noreply.github.com> | 2016-09-25 20:48:31 -0300 |
|---|---|---|
| committer | ariel- <ariel-@users.noreply.github.com> | 2016-10-04 20:21:58 -0300 |
| commit | 2ff855054f52bf2dcf81aa7a7da7bab7f8a99686 (patch) | |
| tree | 29f25fc8bcfede91c6d4960c9ecb8bd1a8ddab49 /src/server/scripts/Kalimdor | |
| parent | e641d0c7d71bdb21e443bf52bf508b1581e07839 (diff) | |
Core/Scripts: Convert spells to new proc system
- Converted Unit::HandleDummyAuraProc function to AuraScripts
* Extra: DMC: Madness now uses DB texts. yay!
* Extra: improvements on Imp. Spell Reflection (range and max targets, filter caster with conditions)
- Fixed Glyph of Succubus. (Closes #6599)
- Changed old (not-blizz) behavior of Vampiric Embrace:
* Before: party heal affected the priest too and self heal was reduced by that amount to not over-heal
* Now: self heal amount not affected, rather filter the priest out of the party heal using conditions :)
- Solve bug in AQ 3p set bonus, it should only trigger when healing others, not self heals.
- Priest T10 2p bonus (heal) now rolls its effect properly
- Use brand new GetEffectiveHeal to fix #17142
- While we're at it, also close #17034 for good
- Converted Unit::HandleAuraProc function to AuraScripts (#17941)
- Converted Unit::HandleAuraProc function to AuraScripts (cont'd) (#17955)
- Corrected Flametongue weapon damage formula
- Actually check offhand weapon for flametongue in Lava Lash script
- Implemented halved proc chance for Missile Barrage on Arcane Barrage, Fireball, Frostbolt and Frostfire Bolt cast
- Converted Unit::HandleProcTriggerSpell function to AuraScripts (#17956)
- De-hack Earth shield. Fixes #13808
- Updated Honor among Thieves
- Implemented mana proc for Mark of Conquest in case of ranged attack
- Fixed Scent of Blood giving more stacks than the talent rank currently learnt.
- Ported old proc table. Proc system is dead. Long live the proc system!
- Recklessness should get charges removed per cast. Closes #15529
- Use proc system to remove Molten Core charges on Incinerate/Soul Fire cast. Closes #15942
Closes #3463
Closes #5401
Closes #15595
Closes #15974
Closes #16679
Closes #17925
Diffstat (limited to 'src/server/scripts/Kalimdor')
| -rw-r--r-- | src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp | 54 |
1 files changed, 48 insertions, 6 deletions
diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp index 5009cce48f4..5d41908435e 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp @@ -17,17 +17,19 @@ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "SpellScript.h" #include "hyjal.h" #include "hyjal_trash.h" enum Spells { - SPELL_CARRION_SWARM = 31306, - SPELL_SLEEP = 31298, - SPELL_VAMPIRIC_AURA = 38196, - SPELL_INFERNO = 31299, - SPELL_IMMOLATION = 31303, - SPELL_INFERNO_EFFECT = 31302, + SPELL_CARRION_SWARM = 31306, + SPELL_SLEEP = 31298, + SPELL_VAMPIRIC_AURA = 38196, + SPELL_VAMPIRIC_AURA_HEAL = 31285, + SPELL_INFERNO = 31299, + SPELL_IMMOLATION = 31303, + SPELL_INFERNO_EFFECT = 31302 }; enum Texts @@ -261,8 +263,48 @@ public: }; +class spell_anetheron_vampiric_aura : public SpellScriptLoader +{ + public: + spell_anetheron_vampiric_aura() : SpellScriptLoader("spell_anetheron_vampiric_aura") { } + + class spell_anetheron_vampiric_aura_AuraScript : public AuraScript + { + PrepareAuraScript(spell_anetheron_vampiric_aura_AuraScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_VAMPIRIC_AURA_HEAL)) + return false; + return true; + } + + void HandleProc(AuraEffect const* /*aurEff*/, ProcEventInfo& eventInfo) + { + PreventDefaultAction(); + DamageInfo* damageInfo = eventInfo.GetDamageInfo(); + if (!damageInfo || !damageInfo->GetDamage()) + return; + + int32 bp = damageInfo->GetDamage() * 3; + eventInfo.GetActor()->CastCustomSpell(SPELL_VAMPIRIC_AURA_HEAL, SPELLVALUE_BASE_POINT0, bp, eventInfo.GetActor(), true); + } + + void Register() override + { + OnEffectProc += AuraEffectProcFn(spell_anetheron_vampiric_aura_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_anetheron_vampiric_aura_AuraScript(); + } +}; + void AddSC_boss_anetheron() { new boss_anetheron(); new npc_towering_infernal(); + new spell_anetheron_vampiric_aura(); } |
