- Fixed: AActor::Slam mzst check the charging monster's health before setting it back to its See state. Damaging the target may cause action that might have killed it.

SVN r2837 (trunk)
This commit is contained in:
Christoph Oelckers 2010-09-19 22:33:21 +00:00
parent a2673c2cc4
commit 59b19d36fb

View file

@ -2626,8 +2626,12 @@ bool AActor::Slam (AActor *thing)
int dam = GetMissileDamage (7, 1);
P_DamageMobj (thing, this, this, dam, NAME_Melee);
P_TraceBleed (dam, thing, this);
if (SeeState != NULL) SetState (SeeState);
else SetIdle();
// The charging monster may have died by the target's actions here.
if (health > 0)
{
if (SeeState != NULL) SetState (SeeState);
else SetIdle();
}
}
else
{