Skip to content

Commit 7abb4d4

Browse files
committed
Escape while ingame returns you to the game.
1 parent f4baccc commit 7abb4d4

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

LuaMenu/widgets/chobby/components/interface_root.lua

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1081,15 +1081,15 @@ function GetInterfaceRoot(optionsParent, mainWindowParent, fontFunction)
10811081
return true
10821082
end
10831083
if key == Spring.GetKeyCode("esc") then
1084+
if showTopBar then
1085+
SetMainInterfaceVisible(false)
1086+
return true
1087+
end
10841088
if rightPanelHandler.CloseTabs() or mainWindowHandler.CloseTabs() or
10851089
(backgroundCloseListener and backgroundCloseListener()) or
10861090
mainWindowHandler.BackOneLevel() or MakeExitPopup() then
10871091
return false
10881092
end
1089-
if showTopBar then
1090-
SetMainInterfaceVisible(false)
1091-
return true
1092-
end
10931093
end
10941094
return false
10951095
end

0 commit comments

Comments
 (0)