fix(launcher): recognize source-built game folders #63

Open
Anarkkie wants to merge 2 commits from Anarkkie/LongshotLauncher:fix/source-built-game-folders into main
First-time contributor

Source-built Longshot games can place the executable in the game folder's root, which the launcher currently marks as not built and cannot start. Recognizing the builder's source and packaged layouts lets these games use the normal Play and save handling.

Prefer bin/longshot[.exe] when present. Otherwise accept longshot[.exe] at the root only when its platform renderer is beside it; a packaged root helper alone does not enable Play. The working directory and existing save arguments are unchanged. Both Windows and Linux layouts emitted by nx2/make_game.py are covered.

Fixes #53.

Validation

Code 4c238d6, based on accepted main 01f2797; the final check against main 9b3d202 applies cleanly. The following documentation commit only records acceptance.

  • Linux strict core: 978 checks; release tooling: 28 tests. Focused Windows folder/launch-command checks: 42. All pass.
  • Locked Release solution builds on Windows and Linux: 0 warnings, 0 errors.
  • Compiled headless launcher checks reproduce disabled Play before the fix and enabled Play afterward. Authored Windows probe executables are actually started through Play for both root and bin layouts, verifying executable, working directory and save argument. A packaged root helper with missing bin executable remains disabled.
  • Native game: nightly-80-7315957c (source cdf3d9d8), Kokiri Forest, Windows 11 Pro 10.0.26300, RTX 3080 Ti / NVIDIA 610.88, Ryzen 7 5800X3D / 32 GB. Both root and bin layouts loaded the intended isolated save, rendered the settled scene, accepted movement and exited 0. Bin won when both executables existed. All 70 original save hashes remained unchanged. Runs are recorded in docs/tested-configurations.md.

Native acceptance ran offscreen with HOS_HEADLESS=1, HOS_AUDIO=0, RX_VK_LOAD=create and RX_VK_PRECOMPILE unset. A prior automatic all-program preload stalled at the intro and was quit cleanly; both controlled layout runs use the same loading policy. No rendering/performance improvement or native Linux gameplay acceptance is claimed.

The standalone full Windows core runner retains the SelfUpdateChecks failure reproduced on unchanged main. That and the other Windows runner/filesystem corrections are submitted separately in #64. A private integration with those fixes and the player/save framework passes Windows/Linux strict core 1,120 / 1,145 and headless UI 290 / 289; those are combined results, not standalone counts for this PR.

Screenshots

Same authored fixture, compiled launcher at 960 x 600; launch-check details.

Before: Play disabled

After: Play enabled

Scope and risk

The fallback requires the supported executable-plus-renderer layout. A failed packaged cleanup leaving a stale root renderer plus a later missing bin executable remains a narrow ambiguity. This does not change installed layouts, launcher arguments or game files.

If merged after #55, retain that feature's explicit Linux --user routing in the new launch-command test; the standalone main-based assertion here preserves main's existing Linux behavior. This combined case has been tested locally.

AI-assisted implementation and independent source review with OpenAI Codex. No game files, real saves or game-derived assets are included.

Source-built Longshot games can place the executable in the game folder's root, which the launcher currently marks as not built and cannot start. Recognizing the builder's source and packaged layouts lets these games use the normal Play and save handling. Prefer `bin/longshot[.exe]` when present. Otherwise accept `longshot[.exe]` at the root only when its platform renderer is beside it; a packaged root helper alone does not enable Play. The working directory and existing save arguments are unchanged. Both Windows and Linux layouts emitted by `nx2/make_game.py` are covered. Fixes #53. ## Validation Code `4c238d6`, based on accepted main `01f2797`; the final check against main `9b3d202` applies cleanly. The following documentation commit only records acceptance. - Linux strict core: **978** checks; release tooling: **28** tests. Focused Windows folder/launch-command checks: **42**. All pass. - Locked Release solution builds on Windows and Linux: **0 warnings, 0 errors**. - Compiled headless launcher checks reproduce disabled Play before the fix and enabled Play afterward. Authored Windows probe executables are actually started through Play for both root and bin layouts, verifying executable, working directory and save argument. A packaged root helper with missing bin executable remains disabled. - Native game: nightly-80-7315957c (source `cdf3d9d8`), Kokiri Forest, Windows 11 Pro 10.0.26300, RTX 3080 Ti / NVIDIA 610.88, Ryzen 7 5800X3D / 32 GB. Both root and bin layouts loaded the intended isolated save, rendered the settled scene, accepted movement and exited **0**. Bin won when both executables existed. All **70** original save hashes remained unchanged. Runs are recorded in `docs/tested-configurations.md`. Native acceptance ran offscreen with `HOS_HEADLESS=1`, `HOS_AUDIO=0`, `RX_VK_LOAD=create` and `RX_VK_PRECOMPILE` unset. A prior automatic all-program preload stalled at the intro and was quit cleanly; both controlled layout runs use the same loading policy. No rendering/performance improvement or native Linux gameplay acceptance is claimed. The standalone full Windows core runner retains the `SelfUpdateChecks` failure reproduced on unchanged main. That and the other Windows runner/filesystem corrections are submitted separately in #64. A private integration with those fixes and the player/save framework passes Windows/Linux strict core **1,120 / 1,145** and headless UI **290 / 289**; those are combined results, not standalone counts for this PR. ## Screenshots Same authored fixture, compiled launcher at 960 x 600; [launch-check details](https://git.magicbean.dev/MagicBeanDev/LongshotLauncher/pulls/63#issuecomment-17829). ![Before: Play disabled](https://git.magicbean.dev/attachments/cd8e605a-2906-4983-9061-54b39b3509d6) ![After: Play enabled](https://git.magicbean.dev/attachments/14925c01-eab1-4107-8db5-817330f763cf) ## Scope and risk The fallback requires the supported executable-plus-renderer layout. A failed packaged cleanup leaving a stale root renderer plus a later missing bin executable remains a narrow ambiguity. This does not change installed layouts, launcher arguments or game files. If merged after #55, retain that feature's explicit Linux `--user` routing in the new launch-command test; the standalone main-based assertion here preserves main's existing Linux behavior. This combined case has been tested locally. AI-assisted implementation and independent source review with OpenAI Codex. No game files, real saves or game-derived assets are included.
test(launcher): record native game layout acceptance
Some checks are pending
CI / Conventional Commit title (pull_request) Blocked by required conditions
CI / Compile and test (pull_request) Blocked by required conditions
381c02df7d
Author
First-time contributor

Same authored root-layout fixture, rendered in the compiled launcher at 960 x 600. Before: the existing root executable is reported missing and Play is disabled. After: the supported executable-plus-renderer layout enables Play; the probe launch also verified executable, working directory and save argument. Native root/bin acceptance and its hardware are recorded in the description.

Before: Play disabled

After: Play enabled

Same authored root-layout fixture, rendered in the compiled launcher at 960 x 600. Before: the existing root executable is reported missing and Play is disabled. After: the supported executable-plus-renderer layout enables Play; the probe launch also verified executable, working directory and save argument. Native root/bin acceptance and its hardware are recorded in the description. ![Before: Play disabled](https://git.magicbean.dev/attachments/cd8e605a-2906-4983-9061-54b39b3509d6) ![After: Play enabled](https://git.magicbean.dev/attachments/14925c01-eab1-4107-8db5-817330f763cf)
Some checks are pending
CI / Conventional Commit title (pull_request) Blocked by required conditions
CI / Compile and test (pull_request) Blocked by required conditions
This pull request doesn't have enough approvals yet. 0 of 1 approvals granted.
Some workflows are waiting to be reviewed.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'fix/source-built-game-folders:Anarkkie-fix/source-built-game-folders'
git switch 'Anarkkie-fix/source-built-game-folders'
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!63
No description provided.