aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/server/game/Entities/Unit/Unit.cpp10
-rw-r--r--src/server/scripts/Spells/spell_priest.cpp41
2 files changed, 38 insertions, 13 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index ce799ab158f..96e41155764 100644
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -5582,16 +5582,6 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
target = this;
break;
}
- // Phantasm
- case 47569:
- case 47570:
- {
- if (!roll_chance_i(triggerAmount))
- return false;
-
- RemoveMovementImpairingAuras();
- break;
- }
// Oracle Healing Bonus ("Garments of the Oracle" set)
case 26169:
{
diff --git a/src/server/scripts/Spells/spell_priest.cpp b/src/server/scripts/Spells/spell_priest.cpp
index c83643af29e..af97959f692 100644
--- a/src/server/scripts/Spells/spell_priest.cpp
+++ b/src/server/scripts/Spells/spell_priest.cpp
@@ -55,7 +55,7 @@ enum PriestSpells
SPELL_PRIEST_SHADOWFORM_VISUAL_WITH_GLYPH = 107904,
SPELL_PRIEST_SHADOW_WORD_DEATH = 32409,
SPELL_PRIEST_T9_HEALING_2P = 67201,
- SPELL_PRIEST_VAMPRIC_EMBRACE = 15290,
+ SPELL_PRIEST_VAMPRIC_EMBRACE_HEAL = 15290,
SPELL_PRIEST_VAMPIRIC_TOUCH_DISPEL = 64085,
};
@@ -584,6 +584,40 @@ class spell_pri_penance : public SpellScriptLoader
}
};
+// -47569 - Phantasm
+class spell_pri_phantasm : public SpellScriptLoader
+{
+ public:
+ spell_pri_phantasm() : SpellScriptLoader("spell_pri_phantasm") { }
+
+ class spell_pri_phantasm_AuraScript : public AuraScript
+ {
+ PrepareAuraScript(spell_pri_phantasm_AuraScript);
+
+ bool CheckProc(ProcEventInfo& /*eventInfo*/)
+ {
+ return roll_chance_i(GetEffect(EFFECT_0)->GetAmount());
+ }
+
+ void HandleEffectProc(AuraEffect const* /*aurEff*/, ProcEventInfo& /*eventInfo*/)
+ {
+ PreventDefaultAction();
+ GetTarget()->RemoveMovementImpairingAuras();
+ }
+
+ void Register() OVERRIDE
+ {
+ DoCheckProc += AuraCheckProcFn(spell_pri_phantasm_AuraScript::CheckProc);
+ OnEffectProc += AuraEffectProcFn(spell_pri_phantasm_AuraScript::HandleEffectProc, EFFECT_0, SPELL_AURA_DUMMY);
+ }
+ };
+
+ AuraScript* GetAuraScript() const OVERRIDE
+ {
+ return new spell_pri_phantasm_AuraScript();
+ }
+};
+
// -17 - Power Word: Shield
class spell_pri_power_word_shield : public SpellScriptLoader
{
@@ -873,7 +907,7 @@ class spell_pri_vampiric_embrace : public SpellScriptLoader
bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE
{
- if (!sSpellMgr->GetSpellInfo(SPELL_PRIEST_VAMPRIC_EMBRACE))
+ if (!sSpellMgr->GetSpellInfo(SPELL_PRIEST_VAMPRIC_EMBRACE_HEAL))
return false;
return true;
}
@@ -890,7 +924,7 @@ class spell_pri_vampiric_embrace : public SpellScriptLoader
int32 self = int32(CalculatePct(eventInfo.GetDamageInfo()->GetDamage(), aurEff->GetAmount()));
int32 team = int32(CalculatePct(eventInfo.GetDamageInfo()->GetDamage(), aurEff->GetAmount() / 2));
- GetTarget()->CastCustomSpell((Unit*)NULL, SPELL_PRIEST_VAMPRIC_EMBRACE, &team, &self, NULL, true, NULL, aurEff);
+ GetTarget()->CastCustomSpell((Unit*)NULL, SPELL_PRIEST_VAMPRIC_EMBRACE_HEAL, &team, &self, NULL, true, NULL, aurEff);
}
void Register() OVERRIDE
@@ -988,6 +1022,7 @@ void AddSC_priest_spell_scripts()
new spell_pri_mind_sear();
new spell_pri_pain_and_suffering_proc();
new spell_pri_penance();
+ new spell_pri_phantasm();
new spell_pri_power_word_shield();
new spell_pri_prayer_of_mending_heal();
new spell_pri_reflective_shield_trigger();