fix(Core/Unit): update death state before handling RemoveAllAurasOnDeath() (#20124)

fix setDeathState

[PATCH] Don't allow units to enter combat upon death
91ebea4a77.patch
Co-authored-by: trickerer <onlysuffering@gmail.com>
This commit is contained in:
Jelle Meeus
2024-10-04 16:01:36 +02:00
committed by GitHub
parent dda54fd638
commit 01b86ec7a6
4 changed files with 6 additions and 7 deletions

View File

@@ -416,7 +416,7 @@ ThreatMgr::ThreatMgr(Unit* owner) : iCurrentVictim(nullptr), iOwner(owner), iUpd
void ThreatMgr::ClearAllThreat()
{
if (iOwner->CanHaveThreatList() && !isThreatListEmpty())
if (iOwner->CanHaveThreatList(true) && !isThreatListEmpty())
iOwner->SendClearThreatListOpcode();
clearReferences();
}