Remove mobj interpolator only after thinker

This commit is contained in:
Eidolon 2022-11-12 14:59:31 -06:00
parent e59684b1a2
commit 3bdfa3b9f4

View file

@ -11178,8 +11178,6 @@ void P_RemoveMobj(mobj_t *mobj)
memset((UINT8 *)mobj + sizeof(thinker_t), 0xff, sizeof(mobj_t) - sizeof(thinker_t));
#endif
R_RemoveMobjInterpolator(mobj);
// free block
if (!mobj->thinker.next)
{ // Uh-oh, the mobj doesn't think, P_RemoveThinker would never go through!
@ -11196,6 +11194,8 @@ void P_RemoveMobj(mobj_t *mobj)
}
P_RemoveThinker((thinker_t *)mobj);
R_RemoveMobjInterpolator(mobj);
}
// This does not need to be added to Lua.