From 6912915304da7f7062f2ab7adb5e80c3746ad2a0 Mon Sep 17 00:00:00 2001 From: SteelT Date: Mon, 21 Sep 2020 15:01:56 -0400 Subject: [PATCH] Fix hitting springs crash MFE_SPRUNG flag not being applied to the object sprung would cause a infinite recursion of `P_TryMove` -> `P_CheckPosition` -> `PIT_CheckThing` -> `P_DoSpring` -> etc Also fix springs not being de-solidfied Dunno what's up with the spring sound not playing --- src/p_map.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/p_map.c b/src/p_map.c index a18be3641..5bf59ca74 100644 --- a/src/p_map.c +++ b/src/p_map.c @@ -271,6 +271,9 @@ boolean P_DoSpring(mobj_t *spring, mobj_t *object) object->standingslope = NULL; // Okay, now we know it's not going to be relevant - no launching off at silly angles for you. + object->eflags |= MFE_SPRUNG; // apply this flag asap! + spring->flags &= ~(MF_SOLID|MF_SPECIAL); // De-solidify + if (spring->eflags & MFE_VERTICALFLIP) vertispeed *= -1;