fixed closing door 2 after door 1 when no tape is to be saved after playing
authorHolger Schemel <info@artsoft.org>
Tue, 14 Nov 2017 21:35:29 +0000 (22:35 +0100)
committerHolger Schemel <info@artsoft.org>
Fri, 23 Mar 2018 22:21:16 +0000 (23:21 +0100)
src/game.c

index 02331879311f3a7680e95bcd80e3a37148220f0e..41768a54c63e6b97aa0a661a9b522d475a25297f 100644 (file)
@@ -4692,14 +4692,16 @@ void GameEnd()
 
   local_player->LevelSolved_GameEnd = TRUE;
 
-  if (!global.use_envelope_request)
-    CloseDoor(DOOR_CLOSE_1);
-
   if (local_player->LevelSolved_SaveTape)
   {
+    /* make sure that request dialog to save tape does not open door again */
+    if (!global.use_envelope_request)
+      CloseDoor(DOOR_CLOSE_1);
+
     SaveTapeChecked(tape.level_nr);    /* ask to save tape */
   }
 
+  /* if no tape is to be saved, close both doors simultaneously */
   CloseDoor(DOOR_CLOSE_ALL);
 
   if (level_editor_test_game)