From 5fa9ba1be0cfa86cd45031c5bc7a02ce9986b7bd Mon Sep 17 00:00:00 2001 From: toaster Date: Fri, 18 Mar 2022 16:56:39 +0000 Subject: [PATCH] move P_MapEnd call in P_LoadLevel further down, so that the P_MapStart/End pair also encloses cached actions and the MapLoad Lua hook # Conflicts: # src/p_setup.c --- src/p_setup.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/p_setup.c b/src/p_setup.c index f3852cade..3280cddef 100644 --- a/src/p_setup.c +++ b/src/p_setup.c @@ -4191,7 +4191,7 @@ boolean P_LoadLevel(boolean fromnetsave, boolean reloadinggamestate) P_ResetTubeWaypoints(); - P_MapStart(); + P_MapStart(); // tmthing can be used starting from this point // init anything that P_SpawnSlopes/P_LoadThings needs to know P_InitSpecials(); @@ -4283,8 +4283,6 @@ boolean P_LoadLevel(boolean fromnetsave, boolean reloadinggamestate) // clear special respawning que iquehead = iquetail = 0; - P_MapEnd(); - // Remove the loading shit from the screen if (rendermode != render_none && !titlemapinaction && !reloadinggamestate) F_WipeColorFill(levelfadecol); @@ -4368,8 +4366,11 @@ boolean P_LoadLevel(boolean fromnetsave, boolean reloadinggamestate) LUAh_MapLoad(); } + K_TimerReset(); + P_MapEnd(); // tmthing is no longer needed from this point onwards + // No render mode or reloading gamestate, stop here. if (rendermode == render_none || reloadinggamestate) return true;