DEADSOFTWARE

fixed unneded pause on some Fn
authorKetmar Dark <ketmar@ketmar.no-ip.org>
Wed, 4 Oct 2017 00:18:30 +0000 (03:18 +0300)
committerKetmar Dark <ketmar@ketmar.no-ip.org>
Wed, 4 Oct 2017 00:19:19 +0000 (03:19 +0300)
http://doom2d.org/forum/viewtopic.php?f=36&t=2469

src/game/g_main.pas

index 2a444ead437b2e2e6cad6313405e344d309ed38d..7de78252194aea44adfb3baf70463f403f5ede8b 100644 (file)
@@ -485,6 +485,7 @@ begin
           Msg.Msg := WM_KEYDOWN;
           Msg.WParam := IK_ESCAPE;
           g_ActiveWindow.OnMessage(Msg);
+          if (not g_Game_IsNet) and (g_ActiveWindow = nil) then g_Game_Pause(false); //Fn loves to do this
         end
         else if (gState <> STATE_FOLD) then
         begin
@@ -514,7 +515,7 @@ begin
       begin // <F2> .. <F6> � <F12>
         if gGameOn and (not gConsoleShow) and (not gChatShow) then
         begin
-          while g_ActiveWindow <> nil do g_GUI_HideWindow(False);
+          while (g_ActiveWindow <> nil) do g_GUI_HideWindow(False);
           if (not g_Game_IsNet) then g_Game_Pause(True);
           case K of
             IK_F2: g_Menu_Show_SaveMenu();