From 14beff2f55f218227fbb28d67a5e921dd0779d23 Mon Sep 17 00:00:00 2001 From: AJ Martinez Date: Mon, 4 Mar 2024 01:17:17 -0700 Subject: [PATCH] Snap BUBBLESHIELDTRAP to toucher when touched (fixes visual disjoint) --- src/p_inter.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/p_inter.c b/src/p_inter.c index 4208d47d8..86a2a2094 100644 --- a/src/p_inter.c +++ b/src/p_inter.c @@ -634,6 +634,14 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck) P_SetTarget(&special->tracer, toucher); toucher->flags |= MF_NOGRAVITY; toucher->momz = (8*toucher->scale) * P_MobjFlip(toucher); + + // Snap to the unfortunate player and quit moving laterally, or we can end up quite far away + special->momx = 0; + special->momy = 0; + special->x = toucher->x; + special->y = toucher->y; + special->z = toucher->z; + S_StartSound(toucher, sfx_s1b2); return;