mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
5
sql/updates/world/master/2017_02_10_01_world.sql
Normal file
5
sql/updates/world/master/2017_02_10_01_world.sql
Normal file
@@ -0,0 +1,5 @@
|
||||
DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_warr_victorious';
|
||||
INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES
|
||||
(34428,'spell_warr_victory_rush');
|
||||
|
||||
DELETE FROM `spell_proc_event` WHERE `entry`=32216;
|
||||
@@ -63,6 +63,8 @@ enum WarriorSpells
|
||||
SPELL_WARRIOR_UNRELENTING_ASSAULT_TRIGGER_2 = 64850,
|
||||
SPELL_WARRIOR_VIGILANCE_PROC = 50725,
|
||||
SPELL_WARRIOR_VENGEANCE = 76691,
|
||||
SPELL_WARRIOR_VICTORIOUS = 32216,
|
||||
SPELL_WARRIOR_VICTORY_RUSH_HEAL = 118779,
|
||||
SPELL_WARRIOR_HEROIC_LEAP_JUMP = 178368,
|
||||
SPELL_WARRIOR_GLYPH_OF_HEROIC_LEAP = 159708,
|
||||
SPELL_WARRIOR_GLYPH_OF_HEROIC_LEAP_BUFF = 133278,
|
||||
@@ -819,32 +821,45 @@ class spell_warr_sword_and_board : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// 32216 - Victorious
|
||||
// 82368 - Victorious
|
||||
class spell_warr_victorious : public SpellScriptLoader
|
||||
// 34428 - Victory Rush
|
||||
class spell_warr_victory_rush : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_warr_victorious() : SpellScriptLoader("spell_warr_victorious") { }
|
||||
spell_warr_victory_rush() : SpellScriptLoader("spell_warr_victory_rush") { }
|
||||
|
||||
class spell_warr_victorious_AuraScript : public AuraScript
|
||||
class spell_warr_victory_rush_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareAuraScript(spell_warr_victorious_AuraScript);
|
||||
PrepareSpellScript(spell_warr_victory_rush_SpellScript);
|
||||
|
||||
void HandleEffectProc(AuraEffect const* /*aurEff*/, ProcEventInfo& /*eventInfo*/)
|
||||
bool Validate(SpellInfo const* /*spellInfo*/) override
|
||||
{
|
||||
PreventDefaultAction();
|
||||
GetTarget()->RemoveAura(GetId());
|
||||
return ValidateSpellInfo
|
||||
({
|
||||
SPELL_WARRIOR_VICTORIOUS,
|
||||
SPELL_WARRIOR_VICTORY_RUSH_HEAL
|
||||
});
|
||||
}
|
||||
|
||||
void HandleHeal()
|
||||
{
|
||||
if (!GetHitUnit())
|
||||
return;
|
||||
|
||||
Unit* caster = GetCaster();
|
||||
|
||||
caster->CastSpell(caster, SPELL_WARRIOR_VICTORY_RUSH_HEAL, true);
|
||||
caster->RemoveAurasDueToSpell(SPELL_WARRIOR_VICTORIOUS);
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
OnEffectProc += AuraEffectProcFn(spell_warr_victorious_AuraScript::HandleEffectProc, EFFECT_0, SPELL_AURA_DUMMY);
|
||||
AfterCast += SpellCastFn(spell_warr_victory_rush_SpellScript::HandleHeal);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const override
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_warr_victorious_AuraScript();
|
||||
return new spell_warr_victory_rush_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1084,7 +1099,7 @@ void AddSC_warrior_spell_scripts()
|
||||
new spell_warr_sudden_death();
|
||||
new spell_warr_sweeping_strikes();
|
||||
new spell_warr_sword_and_board();
|
||||
new spell_warr_victorious();
|
||||
new spell_warr_victory_rush();
|
||||
new spell_warr_vigilance();
|
||||
new spell_warr_vigilance_trigger();
|
||||
new spell_warr_heroic_leap();
|
||||
|
||||
Reference in New Issue
Block a user