Core/Threat: Some corrections to 5709929d2b
Fixes HandleChannelDeathItem (spells such as Drain Soul), which got broken by moving m_deathState = s, thanks Shauren
This commit is contained in:
1 parent
e5268ba0b5
commit
a1ff27a1c6
3 files changed
+53
-64
No files matched your search
@@ -12833,9 +12833,6 @@ void Unit::SetSpeed(UnitMoveType mtype, float rate, bool forced)
|
||||
|
||||
void Unit::setDeathState(DeathState s)
|
||||
{
|
||||
// death state needs to be updated before RemoveAllAurasOnDeath() calls HandleChannelDeathItem(..) so that
|
||||
// it can be used to check creation of death items (such as soul shards).
|
||||
|
||||
if (s != ALIVE && s != JUST_RESPAWNED)
|
||||
{
|
||||
CombatStop();
|
||||
@@ -12880,9 +12877,7 @@ void Unit::setDeathState(DeathState s)
|
||||
zoneScript->OnUnitDeath(this);
|
||||
}
|
||||
else if (s == JUST_RESPAWNED)
|
||||
{
|
||||
RemoveFlag (UNIT_FIELD_FLAGS, UNIT_FLAG_SKINNABLE); // clear skinnable for creature and player (at battleground)
|
||||
}
|
||||
RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_SKINNABLE); // clear skinnable for creature and player (at battleground)
|
||||
|
||||
m_deathState = s;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user