Remove mobj interp. on early-free in P_RemoveMobj

Fixes a crash that occurred frequently in special stages/NiGHTS.
This commit is contained in:
Eidolon 2022-12-04 22:25:23 -06:00
parent 153def463f
commit 5bb7a527a1

View file

@ -11153,6 +11153,7 @@ void P_RemoveMobj(mobj_t *mobj)
INT32 prevreferences;
if (!mobj->thinker.references)
{
R_RemoveMobjInterpolator(mobj);
Z_Free(mobj); // No refrrences? Can be removed immediately! :D
return;
}