fix(Core/Spells): Shadow Word: Death vs critters. (#15594)

Fixes #14299
This commit is contained in:
UltraNix
2023-03-29 06:27:17 +02:00
committed by GitHub
parent 7f711c0f3f
commit 7035e87543
2 changed files with 9 additions and 4 deletions

View File

@@ -17980,8 +17980,10 @@ void Unit::Kill(Unit* killer, Unit* victim, bool durabilityLoss, WeaponAttackTyp
sScriptMgr->OnCreatureKilledByPet( killer->GetCharmerOrOwnerPlayerOrPlayerItself(), victim->ToCreature());
}
if (killer != victim && !victim->IsCritter())
if (killer != victim)
{
Unit::ProcDamageAndSpell(killer, victim, killer ? PROC_FLAG_KILL : 0, PROC_FLAG_KILLED, PROC_EX_NONE, 0, attackType, spellProto, nullptr, -1, spell);
}
// Proc auras on death - must be before aura/combat remove
Unit::ProcDamageAndSpell(victim, nullptr, PROC_FLAG_DEATH, PROC_FLAG_NONE, PROC_EX_NONE, 0, attackType, spellProto, nullptr, -1, spell);