From 8bcc71c6295cd65d3fbb72d9706ef072ff21d4ce Mon Sep 17 00:00:00 2001
From: Riku Salminen <38985578+Riku-S@users.noreply.github.com>
Date: Fri, 26 Feb 2021 15:43:53 +0200
Subject: [PATCH] Disable pausing during score screens in marathon mode

---
 src/d_netcmd.c | 2 +-
 src/p_user.c   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/d_netcmd.c b/src/d_netcmd.c
index 0acbec928a..09f9d46514 100644
--- a/src/d_netcmd.c
+++ b/src/d_netcmd.c
@@ -2130,7 +2130,7 @@ static void Command_Pause(void)
 
 	if (cv_pause.value || server || (IsPlayerAdmin(consoleplayer)))
 	{
-		if (modeattacking || !(gamestate == GS_LEVEL || gamestate == GS_INTERMISSION))
+		if (modeattacking || !(gamestate == GS_LEVEL || gamestate == GS_INTERMISSION) || (marathonmode && gamestate == GS_INTERMISSION))
 		{
 			CONS_Printf(M_GetText("You can't pause here.\n"));
 			return;
diff --git a/src/p_user.c b/src/p_user.c
index a9e1fe9a20..d7ce331772 100644
--- a/src/p_user.c
+++ b/src/p_user.c
@@ -190,7 +190,7 @@ fixed_t P_ReturnThrustY(mobj_t *mo, angle_t angle, fixed_t move)
 boolean P_AutoPause(void)
 {
 	// Don't pause even on menu-up or focus-lost in netgames or record attack
-	if (netgame || modeattacking || gamestate == GS_TITLESCREEN)
+	if (netgame || modeattacking || gamestate == GS_TITLESCREEN || (marathonmode && gamestate == GS_INTERMISSION))
 		return false;
 
 	return (menuactive || ( window_notinfocus && cv_pauseifunfocused.value ));
-- 
GitLab