mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-17 16:10:49 +01:00
Core/Spells: remove 'Vanish Purge' hack, the spell is present on DB and is copy of one in vanilla DBC
Thanks to killerwife for the heads-up
This commit is contained in:
3
sql/updates/world/3.3.5/2018_02_09_00_world_335.sql
Normal file
3
sql/updates/world/3.3.5/2018_02_09_00_world_335.sql
Normal file
@@ -0,0 +1,3 @@
|
||||
DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_rog_vanish';
|
||||
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
|
||||
(-11327, 'spell_rog_vanish');
|
||||
@@ -774,27 +774,6 @@ void Spell::EffectTriggerSpell(SpellEffIndex effIndex)
|
||||
|
||||
break;
|
||||
}
|
||||
// Vanish (not exist)
|
||||
case 18461:
|
||||
{
|
||||
unitTarget->RemoveMovementImpairingAuras(true);
|
||||
unitTarget->RemoveAurasByType(SPELL_AURA_MOD_STALKED);
|
||||
|
||||
// If this spell is given to an NPC, it must handle the rest using its own AI
|
||||
if (unitTarget->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
// See if we already are stealthed. If so, we're done.
|
||||
if (unitTarget->HasAura(1784))
|
||||
return;
|
||||
|
||||
// Reset cooldown on stealth if needed
|
||||
if (unitTarget->GetSpellHistory()->HasCooldown(1784))
|
||||
unitTarget->GetSpellHistory()->ResetCooldown(1784);
|
||||
|
||||
unitTarget->CastSpell(unitTarget, 1784, true);
|
||||
return;
|
||||
}
|
||||
// Demonic Empowerment -- succubus
|
||||
case 54437:
|
||||
{
|
||||
|
||||
@@ -55,7 +55,8 @@ enum RogueSpells
|
||||
SPELL_ROGUE_QUICK_RECOVERY_ENERGY = 31663,
|
||||
SPELL_ROGUE_CRIPPLING_POISON = 3409,
|
||||
SPELL_ROGUE_MASTER_OF_SUBTLETY_BUFF = 31665,
|
||||
SPELL_ROGUE_OVERKILL_BUFF = 58427
|
||||
SPELL_ROGUE_OVERKILL_BUFF = 58427,
|
||||
SPELL_ROGUE_STEALTH = 1784
|
||||
};
|
||||
|
||||
// 13877, 33735, (check 51211, 65956) - Blade Flurry
|
||||
@@ -1116,6 +1117,38 @@ class spell_rog_turn_the_tables : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// -11327 - Vanish
|
||||
class spell_rog_vanish : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_rog_vanish);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/) override
|
||||
{
|
||||
return ValidateSpellInfo({ SPELL_ROGUE_STEALTH });
|
||||
}
|
||||
|
||||
void ApplyStealth(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
|
||||
{
|
||||
Unit* unitTarget = GetTarget();
|
||||
unitTarget->RemoveAurasByType(SPELL_AURA_MOD_STALKED);
|
||||
|
||||
// See if we already are stealthed. If so, we're done.
|
||||
if (unitTarget->HasAura(SPELL_ROGUE_STEALTH))
|
||||
return;
|
||||
|
||||
// Reset cooldown on stealth if needed
|
||||
if (unitTarget->GetSpellHistory()->HasCooldown(SPELL_ROGUE_STEALTH))
|
||||
unitTarget->GetSpellHistory()->ResetCooldown(SPELL_ROGUE_STEALTH);
|
||||
|
||||
unitTarget->CastSpell(nullptr, SPELL_ROGUE_STEALTH, true);
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
AfterEffectApply += AuraEffectApplyFn(spell_rog_vanish::ApplyStealth, EFFECT_1, SPELL_AURA_MOD_STEALTH, AURA_EFFECT_HANDLE_REAL_OR_REAPPLY_MASK);
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_rogue_spell_scripts()
|
||||
{
|
||||
new spell_rog_blade_flurry();
|
||||
@@ -1140,4 +1173,5 @@ void AddSC_rogue_spell_scripts()
|
||||
new spell_rog_honor_among_thieves();
|
||||
new spell_rog_honor_among_thieves_proc();
|
||||
new spell_rog_turn_the_tables();
|
||||
RegisterAuraScript(spell_rog_vanish);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user