Idea: a documented graceful stop for windowless Windows games #83

Open
opened 2026-11-13 02:27:26 +00:00 by mooki · 0 comments

The idea

Give an owned windowless Windows game a documented, bounded way to stop and finish its shutdown work, without requiring a forced process kill. Establish what is and is not drained; do not call a process exit a completed save.

itzdaface reported this while testing the co-op draft: taskkill without /f did not close the windowless games, so he forced them. The relay later removed them as silent rather than receiving a goodbye. Leaving from the visible game's Co-op tab worked. His setup was Windows 11, Ryzen 7 7700X, RTX 3060 12 GB and 32 GB RAM, on the earlier co-op head 71d4ab0f.

I promised to investigate this separately. That result has not been delivered. The original suggestion was to look at a console handler, but the reported command uses a window-close request: adding a console handler alone must not be presented as a proven fix.

The current Windows host has no explicit console-control handler, and a game without a window still has no window to receive that close request. This is source evidence, not a new Windows reproduction. The command-line session work in pull request 47 provides an owned control/stop route, but does not establish save draining. Co-op pull request 68 carries the original discussion; its socket fixes and Windows fixture results do not settle shutdown behavior.

The investigation should distinguish the supported control command, console events and window-close requests, then exercise the intended path on Windows. For co-op, check whether leaving is sent and the hosted relay/session actually stops. A timeout or forced kill must remain visibly different from successful shutdown.

Anything else

This is separate from the two-player feature and from the proposed crash records. It is not permission to kill arbitrary processes, change the firewall or treat pending saves as safe. Windows runtime testing is still needed; no new shutdown implementation or guarantee is claimed here.

Reported on GitHub as NotRexed/Hookshot#2274; taken on there by mooki.

### The idea Give an owned windowless Windows game a documented, bounded way to stop and finish its shutdown work, without requiring a forced process kill. Establish what is and is not drained; do not call a process exit a completed save. [itzdaface reported this while testing the co-op draft](https://github.com/NotRexed/Hookshot/pull/2274#issuecomment-6812494715): `taskkill` without `/f` did not close the windowless games, so he forced them. The relay later removed them as silent rather than receiving a goodbye. Leaving from the visible game's Co-op tab worked. His setup was Windows 11, Ryzen 7 7700X, RTX 3060 12 GB and 32 GB RAM, on the earlier co-op head `71d4ab0f`. I [promised to investigate this separately](https://github.com/NotRexed/Hookshot/pull/2274#issuecomment-6812576925). That result has not been delivered. The original suggestion was to look at a console handler, but the reported command uses a window-close request: adding a console handler alone must not be presented as a proven fix. The current Windows host has no explicit console-control handler, and a game without a window still has no window to receive that close request. This is source evidence, not a new Windows reproduction. The [command-line session work in pull request 47](https://git.magicbean.dev/MagicBeanDev/Longshot/pulls/47) provides an owned control/stop route, but does not establish save draining. [Co-op pull request 68](https://git.magicbean.dev/MagicBeanDev/Longshot/pulls/68) carries the original discussion; its socket fixes and Windows fixture results do not settle shutdown behavior. The investigation should distinguish the supported control command, console events and window-close requests, then exercise the intended path on Windows. For co-op, check whether leaving is sent and the hosted relay/session actually stops. A timeout or forced kill must remain visibly different from successful shutdown. ### Anything else This is separate from the two-player feature and from the proposed crash records. It is not permission to kill arbitrary processes, change the firewall or treat pending saves as safe. Windows runtime testing is still needed; no new shutdown implementation or guarantee is claimed here. Reported on GitHub as NotRexed/Hookshot#2274; taken on there by mooki.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MagicBeanDev/Longshot#83
No description provided.