fragglet / sdl-sopwith

Classic bi-plane shoot-'em up
https://fragglet.github.io/sdl-sopwith
GNU General Public License v2.0
66 stars 13 forks source link

Add new in-game hotkeys "quit to menu" and "quick restart" #26

Closed techknight closed 7 months ago

techknight commented 7 months ago

Summary

This is a new feature that adds two hotkeys during single player gameplay. When a network game is active, the two hotkeys are disabled.

Quit to Menu

Pressing ctrl+q quits back to the menu. This differs from the existing ctrl+break hotkey, which instead crashes the player's plane, and then exits the program completely.

Quick Restart

Pressing ctrl+r instantly restarts the game in the current mode, at the starting level. If a starting level was specified as a command-line option using -g#, that level is used.

slicer69 commented 7 months ago

This all sounds good. I'm going to give this change a test run.

slicer69 commented 7 months ago

Tested and confirmed this works as expected in both single player mode and that it's disabled (as expected) in network mode. Thank you!

techknight commented 7 months ago

Thanks for reviewing!