fixed another bug with game restart request when opening/closing doors
authorHolger Schemel <info@artsoft.org>
Fri, 5 Apr 2024 15:43:11 +0000 (17:43 +0200)
committerHolger Schemel <info@artsoft.org>
Fri, 5 Apr 2024 15:43:13 +0000 (17:43 +0200)
src/game.c

index 5c3cc9d3d36ec3072332dbea5ec6cd6e2ee2fe7d..ec86a61f86edcfde7e1b1fbe15decc49a91f41b1 100644 (file)
@@ -5165,6 +5165,10 @@ void GameEnd(void)
   // Important note: This function is not only called after "GameWon()", but also after
   // "game over" (if automatically asking for restarting the game is disabled in setup)
 
+  // do not handle game end if request dialog is already active
+  if (checkRequestActive())
+    return;
+
   if (game.LevelSolved)
     game.LevelSolved_GameEnd = TRUE;