fix(Core/Spells): show Execute/Slam misses/dodges/parries in combat log (#7494)

- Closes #7428.
This commit is contained in:
UltraNix
2021-08-26 11:45:22 +02:00
committed by GitHub
parent 5c97632cc3
commit 45218224b4
13 changed files with 118 additions and 26 deletions

View File

@@ -241,8 +241,13 @@ public:
return GetCaster()->GetTypeId() == TYPEID_PLAYER && GetCastItem();
}
void HandleBeforeHit()
void HandleBeforeHit(SpellMissInfo missInfo)
{
if (missInfo != SPELL_MISS_NONE)
{
return;
}
if (Unit* target = GetHitUnit())
// Deadly Poison
if (AuraEffect const* aurEff = target->GetAuraEffect(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_ROGUE, 0x10000, 0x80000, 0, GetCaster()->GetGUID()))
@@ -305,7 +310,7 @@ public:
void Register() override
{
BeforeHit += SpellHitFn(spell_rog_deadly_poison_SpellScript::HandleBeforeHit);
BeforeHit += BeforeSpellHitFn(spell_rog_deadly_poison_SpellScript::HandleBeforeHit);
AfterHit += SpellHitFn(spell_rog_deadly_poison_SpellScript::HandleAfterHit);
}