sm64coopdx
sm64coopdx copied to clipboard
Add options for reducing the framerate and muting the window when coopdx loses focus
This PR adds:
- A new function to the window manager API,
bool (*has_focus)(void)
that checks if the window actively has focus (specifically checks for Keyboard Input on SDL) - 2 new options in game
- Reduce framerate on window focus lost (power saving, default: true)
- Mute game audio on window focus lost (distraction-preventing, default: true)
The English text that I added for the new settings could probably be improved.
Let me know if theres a compilation/code issue for the DXGI and SDL1 window api backends.
Tested using SDL2 and DXGI.