I just found out that there is a way to make your game quit back to blender without pressing esc. If you are making a game and want a quit option on the menu, and want it to quit to blender while running from blender mode, and close a runtime if running as a runtime, this might work. It won’t however solve the problem of disabling the esc key in fullscreen mode runtimes or blender-mode games. The only mode where the esc key doesnt quit is with windowed runtimes.
If you use a remove scene actuator, and remove all the scenes to the point in which there are no scenes left, blender will boot you back into blender.
If you have a menu with a quit option, attach the quit option to two actuators: A gameactuator, and a scene actuator. Set the game actuator to “quit this game” and the scene actuator to “remove scene”. For the remove scene, set it to the name of the current scene (at the top of the blender interface where it says “SCE:”. Whatever is after SCE: is the scenes name).
If you have more scenes than that, I would use a message, and have an empty on each scene that calls a remove scene actuator for that particular scene.
Now, the quit option should be able to quit in all modes of running the game!