refactor(update): the game no longer checks for updates; its folder's launcher does #26
No reviewers
Labels
No labels
accessibility
autorelease: pending
autorelease: tagged
bug
dependencies
documentation
duplicate
enhancement
github_actions
good first issue
help wanted
invalid
needs measurements
question
testing wanted
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!26
Loading…
Reference in a new issue
No description provided.
Delete branch "dyst/Longshot:feat/no-game-update-check"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Carried over from NotRexed/Hookshot#2926 with the move to Longshot: the same change on Longshot's
main, with its rename applied. Its review and discussion are there.The game folder's launcher already asks GitHub for a newer release before the game starts and offers Update there, so the game's own check only asked a second time, and held the game's start on the network (WinHTTP timeouts up to about 3 s on Windows, curl up to about 8 s on Linux) whenever it was started directly. With updates owned by the launcher, the game no longer needs to check, wait or remember anything about releases.
Change
host/hos_update.cremoved, and its call inhos_main.c(after the saves' place is set). The game no longer links WinHTTP (nx2/build.py's-lwinhttp); nothing else inhost/orgpu/used it.Longshot Launcher.exein the game folder (builder/setup/setup.claunch mode) opens the installed builder with--launch <folder>: Play, and Update when a newer release is out. Portable folders (builder_local=1) are covered there too (portable_home.h).longshotin the game folder (builder/linux/longshot-folder) starts the builder with--launch <folder>: the same.bin/longshot(.exe)started by hand, or a development build without a launcher, asks nothing now.longshot_version.txt:builder_args=is no longer written; only the game's check read it.version=,builder=(read by the Linux folder launcher) andbuilder_local=1stay.LONGSHOT_NO_UPDATE_CHECK=1is still set by the launchers and builders' Play: a game folder built before this change still runs its own check without it.hos_update.cnow name the launcher or the setup.Testing
tests/test_update_tracks.py: compiles the setup'snightly_tagand checks the Linux updater's rules as before; the game's C copy of the rules is gone, and with it its checks.tests/test_linux_update_skip.py(the game's "Skip this version" on Linux) andtests/test_portable_local_builder.py(the game's choice of a portable folder's builder) are removed with the code they compiled.run_all.pywith the Builder's tools, Windows: 93 pass. The 5 that fail (nx2/test_dll.py,test_driver_cache_folder,test_fpx_sticky,test_linux_update,test_udmabuf_warning) fail the same way onmainon this PC.test_update_tracks,test_linux_update,test_longshot_launch,test_portable_game_home,test_failed_compile_keeps_objectspass.llvm-objdump -p: nowinhttp.dllimport; noapi.github.comin the exe), starts from a save into Kokiri Forest and plays (33-37 fps there, as before), and its log has no update-check lines and no errors.Docs that describe the game's check (
docs/versioning.md,docs/windows-portable-builder.md) are left for a docs change.Checks on Longshot
Longshot is a fork of GitHub's
mainwith its rename, and nothing here changed in the architecture, so the checks and the in-game runs above were done on the GitHub version: this branch is the same change with the rename applied (the same files and line counts). Forgejo runs no checks; they were not run again here.🤖 Generated with Claude Code
Back to WIP under #48's process: this was carried over before the new template. Its description will be brought to the template and measured on Longshot (main against this PR, at named commits) when it's wanted for review; ask here if you'd like it sooner.
Pull request closed