6 Commits
Author SHA1 Message Date
luis 2c6bccb220 Core/Spells: fix spells with SPELL_AURA_OVERRIDE_ACTIONBAR_SPELLS not being allowed to be cast 2026-11-05 20:17:07 -03:00
luis 2d2bd96014 spells and silvermoon city 2026-11-05 20:08:22 -03:00
luis 36ce8d4d39 Immolation Aura full 2026-11-05 15:19:23 -03:00
luis 88012e5932 duplicate 2026-11-05 15:12:43 -03:00
luis 0d5d67c3ad dh spells 2026-11-05 15:11:02 -03:00
luis 7389cf1923 db sniffs and quests 2026-11-05 15:05:26 -03:00
4 changed files with 2482 additions and 13 deletions
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
@@ -33891,6 +33891,11 @@ void Player::ExecutePendingSpellCastRequest()
if (go->GetSpellForLock(plrCaster) == spellInfo)
allow = true;
// allow casting of spells granted by action bar override auras (e.g. Void Elf Spatial Rift reactivation)
if (castingUnit->HasAuraTypeWithValue(SPELL_AURA_OVERRIDE_ACTIONBAR_SPELLS, spellInfo->Id)
|| castingUnit->HasAuraTypeWithValue(SPELL_AURA_OVERRIDE_ACTIONBAR_SPELLS_TRIGGERED, spellInfo->Id))
allow = true;
// allow casting of spells triggered by clientside periodic trigger auras
if (castingUnit->HasAuraTypeWithTriggerSpell(SPELL_AURA_PERIODIC_TRIGGER_SPELL_FROM_CLIENT, spellInfo->Id))
{
+58 -13
View File
@@ -322,6 +322,8 @@ enum DemonHunterSpells
SPELL_DH_VOIDBLADE = 1245412,
SPELL_DH_CONSUME_MAGIC = 1277738,
SPELL_DH_SWALLOWED_ANGER = 320313,
SPELL_DH_REAPERS_TOLL = 1245470,
SPELL_DH_REAPERS_TOLL_ENABLER = 1245523,
};
enum DemonHunterSpellCategories
@@ -1777,31 +1779,41 @@ class spell_dh_hungering_slash_enabler : public SpellScript
}
};
class spell_dh_hungering_slash_enabler_aura : public AuraScript
// 258920 - Immolation Aura
// 427912 - Immolation Aura
// 427913 - Immolation Aura
// 427914 - Immolation Aura
// 427915 - Immolation Aura
// 258922 - Immolation Aura (periodic tick)
// 427908 - Immolation Aura (periodic tick)
// 427910 - Immolation Aura (periodic tick)
// 427911 - Immolation Aura (periodic tick)
// 427916 - Immolation Aura (periodic tick)
class spell_dh_immolation_aura_energize : public SpellScript
{
bool Validate(SpellInfo const* /*spellInfo*/) override
bool Validate(SpellInfo const* spellInfo) override
{
return ValidateSpellInfo({ SPELL_DH_HUNGERING_SLASH_TALENT, SPELL_DH_HUNGERING_SLASH_ENABLER, SPELL_DH_THE_HUNT });
return ValidateSpellEffect({ { spellInfo->Id, EFFECT_2 } })
&& spellInfo->GetEffect(EFFECT_1).IsEffect(SPELL_EFFECT_ENERGIZE)
&& spellInfo->GetEffect(EFFECT_2).IsEffect(SPELL_EFFECT_ENERGIZE);
}
bool Load() override
{
return GetUnitOwner()->HasAura(SPELL_DH_HUNGERING_SLASH_TALENT);
return GetCaster()->IsPlayer();
}
void HandleEnabler(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/) const
template <ChrSpecialization Spec>
void PreventEffect(WorldObject*& target) const
{
Unit* target = GetTarget();
target->CastSpell(target, SPELL_DH_HUNGERING_SLASH_ENABLER, CastSpellExtraArgsInit{
.TriggerFlags = TRIGGERED_IGNORE_CAST_IN_PROGRESS | TRIGGERED_DONT_REPORT_CAST_ERROR,
.TriggeringAura = aurEff
});
if (GetCaster()->ToPlayer()->GetPrimarySpecialization() != Spec)
target = nullptr;
}
void Register() override
{
if (m_scriptSpellId == SPELL_DH_THE_HUNT)
AfterEffectRemove += AuraEffectRemoveFn(spell_dh_hungering_slash_enabler_aura::HandleEnabler, EFFECT_3, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
OnObjectTargetSelect += SpellObjectTargetSelectFn(spell_dh_immolation_aura_energize::PreventEffect<ChrSpecialization::DemonHunterHavoc>, EFFECT_1, TARGET_UNIT_CASTER);
OnObjectTargetSelect += SpellObjectTargetSelectFn(spell_dh_immolation_aura_energize::PreventEffect<ChrSpecialization::DemonHunterVengeance>, EFFECT_2, TARGET_UNIT_CASTER);
}
};
@@ -2283,6 +2295,36 @@ class spell_dh_reap : public SpellScript
}
};
// 1239519 - Hungering Slash (attached to 1259431 - Predator's Wake and 1245483 - Pierce the Veil)
class spell_dh_reapers_toll_enabler : public SpellScript
{
bool Validate(SpellInfo const* spellInfo) override
{
return ValidateSpellInfo({ SPELL_DH_HUNGERING_SLASH_TALENT, SPELL_DH_REAPERS_TOLL_ENABLER })
&& ValidateSpellEffect({ { spellInfo->Id, EFFECT_0 } })
&& spellInfo->GetEffect(EFFECT_0).TargetA.GetTarget() == TARGET_UNIT_TARGET_ENEMY;
}
bool Load() override
{
return GetCaster()->HasAura(SPELL_DH_HUNGERING_SLASH_TALENT);
}
void HandleEnabler(SpellEffIndex /*effIndex*/) const
{
Unit* caster = GetCaster();
caster->CastSpell(caster, SPELL_DH_REAPERS_TOLL_ENABLER, CastSpellExtraArgsInit{
.TriggerFlags = TRIGGERED_IGNORE_CAST_IN_PROGRESS | TRIGGERED_DONT_REPORT_CAST_ERROR,
.TriggeringSpell = GetSpell()
});
}
void Register() override
{
OnEffectHitTarget += SpellEffectFn(spell_dh_reapers_toll_enabler::HandleEnabler, EFFECT_0, SPELL_EFFECT_ANY);
}
};
// 339895 - Repeat Decree (attached to 307046 - Elysian Decree and 389860 - Sigil of Spite)
class spell_dh_repeat_decree_conduit : public SpellScript
{
@@ -3137,6 +3179,7 @@ class spell_dh_violent_transformation : public AuraScript
};
// 1245412 - Voidblade
// 1245483 - Pierce the Veil
class spell_dh_voidblade : public SpellScript
{
bool Validate(SpellInfo const* /*spellInfo*/) override
@@ -3860,7 +3903,8 @@ void AddSC_demon_hunter_spell_scripts()
RegisterAreaTriggerAI(at_dh_glaive_tempest);
RegisterSpellScript(spell_dh_hungering_slash);
RegisterSpellScript(spell_dh_hungering_slash_damage);
RegisterSpellAndAuraScriptPair(spell_dh_hungering_slash_enabler, spell_dh_hungering_slash_enabler_aura);
RegisterSpellScript(spell_dh_hungering_slash_enabler);
RegisterSpellScript(spell_dh_immolation_aura_energize);
RegisterSpellScript(spell_dh_infernal_armor);
RegisterSpellScript(spell_dh_inner_demon);
RegisterAreaTriggerAI(at_dh_inner_demon);
@@ -3872,6 +3916,7 @@ void AddSC_demon_hunter_spell_scripts()
RegisterSpellScript(spell_dh_painbringer);
RegisterSpellScript(spell_dh_painbringer_reduce_damage);
RegisterSpellScript(spell_dh_reap);
RegisterSpellScript(spell_dh_reapers_toll_enabler);
RegisterSpellScript(spell_dh_repeat_decree_conduit);
RegisterSpellScript(spell_dh_restless_hunter);
RegisterSpellScript(spell_dh_retaliation);