Skip to content
This repository has been archived by the owner on Feb 29, 2024. It is now read-only.

Commit

Permalink
Scripts/Spells: Remove some Obsolete Priest stuff.
Browse files Browse the repository at this point in the history
Signed-off-by: AriDEV <aridev666@gmail.com>
  • Loading branch information
AriDEV committed Mar 8, 2019
1 parent f054098 commit 69908f9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 63 deletions.
2 changes: 2 additions & 0 deletions sql/updates/world/2019_03_08_00_world.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
DELETE FROM spell_script_names WHERE ScriptName='spell_pri_glyph_of_prayer_of_healing';
DELETE FROM spell_script_names WHERE spell_id=55680;
65 changes: 2 additions & 63 deletions src/server/scripts/Spells/spell_priest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,10 @@

enum PriestSpells
{
SPELL_PRIEST_BODY_AND_SOUL_DISPEL = 64136,
SPELL_PRIEST_BODY_AND_SOUL_SPEED = 65081,
SPELL_PRIEST_CURE_DISEASE = 528,
SPELL_PRIEST_DIVINE_AEGIS = 47753,
SPELL_PRIEST_DIVINE_TOUCH = 63544,
SPELL_PRIEST_GLYPH_OF_LIGHTWELL = 55673,
SPELL_PRIEST_GLYPH_OF_PRAYER_OF_HEALING_HEAL = 56161,
SPELL_PRIEST_GLYPH_OF_SHADOW = 107906,
SPELL_PRIEST_ITEM_EFFICIENCY = 37595,
SPELL_PRIEST_LEAP_OF_FAITH = 73325,
Expand All @@ -48,12 +45,11 @@ enum PriestSpells
SPELL_PRIEST_PENANCE_R1 = 47540,
SPELL_PRIEST_PENANCE_R1_DAMAGE = 47758,
SPELL_PRIEST_PENANCE_R1_HEAL = 47757,
SPELL_PRIEST_REFLECTIVE_SHIELD_R1 = 33201,
SPELL_PRIEST_REFLECTIVE_SHIELD_R1 = 33201, // obsolete
SPELL_PRIEST_REFLECTIVE_SHIELD_TRIGGERED = 33619,
SPELL_PRIEST_SHADOWFORM_VISUAL_WITHOUT_GLYPH = 107903,
SPELL_PRIEST_SHADOWFORM_VISUAL_WITH_GLYPH = 107904,
SPELL_PRIEST_SHADOW_WORD_DEATH = 32409,
SPELL_PRIEST_TWIN_DISCIPLINES_RANK_1 = 47586,
SPELL_PRIEST_T9_HEALING_2P = 67201,
SPELL_PRIEST_VAMPIRIC_EMBRACE_HEAL = 15290,
};
Expand Down Expand Up @@ -81,8 +77,7 @@ class spell_pri_body_and_soul : public SpellScriptLoader

bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE
{
if (!sSpellMgr->GetSpellInfo(SPELL_PRIEST_CURE_DISEASE) ||
!sSpellMgr->GetSpellInfo(SPELL_PRIEST_BODY_AND_SOUL_DISPEL))
if (!sSpellMgr->GetSpellInfo(SPELL_PRIEST_BODY_AND_SOUL_SPEED))
return false;
return true;
}
Expand All @@ -96,22 +91,9 @@ class spell_pri_body_and_soul : public SpellScriptLoader

GetTarget()->CastCustomSpell(SPELL_PRIEST_BODY_AND_SOUL_SPEED, SPELLVALUE_BASE_POINT0, aurEff->GetAmount(), eventInfo.GetProcTarget(), true, NULL, aurEff);
}

void HandleEffectDispelProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
{
PreventDefaultAction();
// Proc only with Cure Disease
if (eventInfo.GetDamageInfo()->GetSpellInfo()->Id != SPELL_PRIEST_CURE_DISEASE || eventInfo.GetProcTarget() != GetTarget())
return;

if (roll_chance_i(aurEff->GetAmount()))
GetTarget()->CastSpell(eventInfo.GetProcTarget(), SPELL_PRIEST_BODY_AND_SOUL_DISPEL, true, NULL, aurEff);
}

void Register() OVERRIDE
{
OnEffectProc += AuraEffectProcFn(spell_pri_body_and_soul_AuraScript::HandleEffectSpeedProc, EFFECT_0, SPELL_AURA_DUMMY);
OnEffectProc += AuraEffectProcFn(spell_pri_body_and_soul_AuraScript::HandleEffectDispelProc, EFFECT_1, SPELL_AURA_DUMMY);
}
};

Expand Down Expand Up @@ -171,44 +153,6 @@ class spell_pri_divine_aegis : public SpellScriptLoader
}
};

// 55680 - Glyph of Prayer of Healing
class spell_pri_glyph_of_prayer_of_healing : public SpellScriptLoader
{
public:
spell_pri_glyph_of_prayer_of_healing() : SpellScriptLoader("spell_pri_glyph_of_prayer_of_healing") { }

class spell_pri_glyph_of_prayer_of_healing_AuraScript : public AuraScript
{
PrepareAuraScript(spell_pri_glyph_of_prayer_of_healing_AuraScript);

bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE
{
if (!sSpellMgr->GetSpellInfo(SPELL_PRIEST_GLYPH_OF_PRAYER_OF_HEALING_HEAL))
return false;
return true;
}

void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
{
PreventDefaultAction();

SpellInfo const* triggeredSpellInfo = sSpellMgr->GetSpellInfo(SPELL_PRIEST_GLYPH_OF_PRAYER_OF_HEALING_HEAL);
int32 heal = int32(CalculatePct(int32(eventInfo.GetHealInfo()->GetHeal()), aurEff->GetAmount()) / triggeredSpellInfo->GetMaxTicks());
GetTarget()->CastCustomSpell(SPELL_PRIEST_GLYPH_OF_PRAYER_OF_HEALING_HEAL, SPELLVALUE_BASE_POINT0, heal, eventInfo.GetProcTarget(), true, NULL, aurEff);
}

void Register() OVERRIDE
{
OnEffectProc += AuraEffectProcFn(spell_pri_glyph_of_prayer_of_healing_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
}
};

AuraScript* GetAuraScript() const OVERRIDE
{
return new spell_pri_glyph_of_prayer_of_healing_AuraScript();
}
};

class spell_pri_improved_power_word_shield : public SpellScriptLoader
{
public:
Expand Down Expand Up @@ -634,10 +578,6 @@ class spell_pri_power_word_shield : public SpellScriptLoader

amount += int32(bonus);

// Twin Disciplines
if (AuraEffect const* twinDisciplines = caster->GetAuraEffectOfRankedSpell(SPELL_PRIEST_TWIN_DISCIPLINES_RANK_1, EFFECT_1))
AddPct(amount, twinDisciplines->GetAmount());

// Focused Power
amount *= caster->GetTotalAuraMultiplier(SPELL_AURA_MOD_HEALING_DONE_PERCENT);
}
Expand Down Expand Up @@ -943,7 +883,6 @@ void AddSC_priest_spell_scripts()
{
new spell_pri_body_and_soul();
new spell_pri_divine_aegis();
new spell_pri_glyph_of_prayer_of_healing();
new spell_pri_improved_power_word_shield();
new spell_pri_item_greater_heal_refund();
new spell_pri_leap_of_faith_effect_trigger();
Expand Down

0 comments on commit 69908f9

Please sign in to comment.