From 813ed81a37dda29e3d959a73cce1fd3568218814 Mon Sep 17 00:00:00 2001 From: Eidolon Date: Wed, 27 Apr 2022 19:52:11 -0500 Subject: [PATCH] Reset old_z in MT_LOCKON think Fixes interpolation artifacting due to spawn pos. --- src/p_mobj.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/p_mobj.c b/src/p_mobj.c index b5c83468a..88c269b26 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -7800,6 +7800,9 @@ static void P_MobjSceneryThink(mobj_t *mobj) mobj->z = mobj->target->z + mobj->target->height + FixedMul((16 + abs((signed)(leveltime % TICRATE) - TICRATE/2))*FRACUNIT, mobj->target->scale); else mobj->z = mobj->target->z - FixedMul((16 + abs((signed)(leveltime % TICRATE) - TICRATE/2))*FRACUNIT, mobj->target->scale) - mobj->height; + + mobj->old_z = mobj->z; + break; case MT_LOCKONINF: if (!(mobj->flags2 & MF2_STRONGBOX)) @@ -7811,6 +7814,9 @@ static void P_MobjSceneryThink(mobj_t *mobj) mobj->z = mobj->threshold + FixedMul((16 + abs((signed)(leveltime % TICRATE) - TICRATE/2))*FRACUNIT, mobj->scale); else mobj->z = mobj->threshold - FixedMul((16 + abs((signed)(leveltime % TICRATE) - TICRATE/2))*FRACUNIT, mobj->scale); + + mobj->old_z = mobj->z; + break; case MT_DROWNNUMBERS: if (!P_DrownNumbersSceneryThink(mobj))