feat(tools): the launcher's screens drawn without a display into PNGs, for pull requests and the README #85

Merged
HumanBean merged 1 commit from HumanBean/LongshotLauncher:feat/screenshot-tool into main 2026-11-15 08:02:47 +00:00
Owner

Pull requests that change a screen should include screenshots, but the only way to get them was to run the launcher by hand on a real desktop: a real home, real saves, real paths, and a real game build to reach the build page. This adds a tool that draws the screens without a display, the same way every time, with nothing from the PC that draws them.

What changed

  • tools/screenshots (new): dotnet run --project tools/screenshots -- <out folder> [scene ...] renders the 960x600 window through Avalonia.Headless and Skia into one PNG per scene:
    • home
    • settings-linux (AMD GPU)
    • settings-windows (NVIDIA GPU)
    • fsr-linux-notice
    • build (reading the game files)
    • build-log (Show details at Debug, from a replayed make_game transcript)
  • Nothing of the PC in the pictures. Each scene runs in a launcher of its own:
    • a home in a temporary folder, deleted afterwards;
    • a player's folders (/home/player/..., C:\Users\Player\...);
    • saves looked for in an empty home, so neither real Longshot nor real Hookshot saves are found;
    • a stand-in answer for the update check (SetNewest), so nothing goes over the network;
    • a set amount of free space;
    • a stand-in drive name, through the new Disk.ShownDrive. Without it, a Windows path on Linux resolved against the current folder and showed this PC's mount point.
  • Directory.Packages.props pins Avalonia.Headless 12.1.6 (the Avalonia version in use). The tool has its own packages.lock.json, and it's in LongshotLauncher.slnx, so CI compiles it and it keeps up with the views. It isn't part of the release programs (package.sh publishes App only).
  • README: a Screenshots section, and the tool in the layout table.

Testing

Tested on Linux:

  • The tool built (no warnings) and drew all 6 scenes, below.
  • python -I tests/test_launcher_core.py: 1058 checks passed.
  • python -I tests/test_release.py: OK.

Not tested: running the tool on Windows.

Screenshots

What the tool draws, from this branch:

home

home

settings-linux

settings-linux

settings-windows

settings-windows

fsr-linux-notice

fsr-linux-notice

build

build

build-log

build-log

Pull requests that change a screen should include screenshots, but the only way to get them was to run the launcher by hand on a real desktop: a real home, real saves, real paths, and a real game build to reach the build page. This adds a tool that draws the screens without a display, the same way every time, with nothing from the PC that draws them. ## What changed - `tools/screenshots` (new): `dotnet run --project tools/screenshots -- <out folder> [scene ...]` renders the 960x600 window through Avalonia.Headless and Skia into one PNG per scene: - `home` - `settings-linux` (AMD GPU) - `settings-windows` (NVIDIA GPU) - `fsr-linux-notice` - `build` (reading the game files) - `build-log` (Show details at Debug, from a replayed make_game transcript) - **Nothing of the PC in the pictures.** Each scene runs in a launcher of its own: - a home in a temporary folder, deleted afterwards; - a player's folders (`/home/player/...`, `C:\Users\Player\...`); - saves looked for in an empty home, so neither real Longshot nor real Hookshot saves are found; - a stand-in answer for the update check (`SetNewest`), so nothing goes over the network; - a set amount of free space; - a stand-in drive name, through the new `Disk.ShownDrive`. Without it, a Windows path on Linux resolved against the current folder and showed this PC's mount point. - `Directory.Packages.props` pins `Avalonia.Headless` 12.1.6 (the Avalonia version in use). The tool has its own `packages.lock.json`, and it's in `LongshotLauncher.slnx`, so CI compiles it and it keeps up with the views. It isn't part of the release programs (`package.sh` publishes `App` only). - README: a Screenshots section, and the tool in the layout table. ## Testing **Tested** on Linux: - The tool built (no warnings) and drew all 6 scenes, below. - `python -I tests/test_launcher_core.py`: 1058 checks passed. - `python -I tests/test_release.py`: OK. **Not tested:** running the tool on Windows. ## Screenshots What the tool draws, from this branch: **home** ![home](https://git.magicbean.dev/attachments/da03d863-f6d3-43dd-a502-90e8480ccbee) **settings-linux** ![settings-linux](https://git.magicbean.dev/attachments/4b52ff2b-2e75-47b4-9e6e-2ad13c6e662f) **settings-windows** ![settings-windows](https://git.magicbean.dev/attachments/54f6e256-999e-4b39-b306-36b171e6c6e1) **fsr-linux-notice** ![fsr-linux-notice](https://git.magicbean.dev/attachments/e84b21e4-62f3-45b9-84bf-81f501709ad9) **build** ![build](https://git.magicbean.dev/attachments/f9e20f59-a32f-4c6d-ab27-7b4c0e0fc0af) **build-log** ![build-log](https://git.magicbean.dev/attachments/a9d09d65-806b-44f2-9d4a-9100d06c7d14)
feat(tools): the launcher's screens drawn without a display into PNGs, for pull requests and the README
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 4s
e873b0da8e
tools/screenshots renders scenes through Avalonia.Headless and Skia: the home, the build settings on Linux and Windows, the
AMD FSR 4 notice, and the build page with and without its details. Each scene runs in a launcher of its own: a home in a
temporary folder, a player's folders, saves looked for in an empty home, a stand-in answer for the update check, and a
stand-in drive (Disk.ShownDrive), so nothing of the PC that draws them is in the pictures and nothing goes over the network.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
HumanBean deleted branch feat/screenshot-tool 2026-11-15 08:02:48 +00:00
Sign in to join this conversation.
No reviewers
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/LongshotLauncher!85
No description provided.