Snap BUBBLESHIELDTRAP to toucher when touched (fixes visual disjoint)

This commit is contained in:
AJ Martinez 2024-03-04 01:17:17 -07:00 committed by NepDisk
parent 0882846d29
commit 32bc196381

View file

@ -642,6 +642,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;
case MT_RING: