fix(build): the game's window and taskbar icon is Longshot's, not the old Hookshot one #1764
No reviewers
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/renderer
area/saves
area/tooling
area/upscaling
beanstalk: approved
beanstalk: failed
beanstalk: needs approval
beanstalk: running
beanstalk: tested
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
risk
high
risk
low
risk
medium
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!1764
Loading…
Reference in a new issue
No description provided.
Delete branch "dyst/Longshot:fix/brand-icon"
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?
Type: fix · Risk: low · Tested on: Windows 11, RTX 3080, Ryzen 9 3900X · Needs: nothing
TL;DR
The game's window and taskbar have shown the old blue Hookshot icon since the project became Longshot, in every build, 3.0.0 included. The icon file was renamed in the rename commit but its picture was never replaced. This makes it again from
assets/longshot.png, the green Longshot logo the README and the start-up screen already use, and adds a check that the icon is that picture, so the next logo change can't leave it behind.Breakdown
builder/setup/longshot.ico, which every build links into the game's exe, is byte for byte thehookshot.icoit was renamed from ine2a4d453("Rename the project to Longshot"); that commit gave the PNGs the new art but not the .ico.assets/longshot.pngwithnx2/make_icon.py(its seven sizes, Pillow 13.0.0 as pinned);tests/test_exe_icon.pychecks its 32 and 256 pixel images against the logo.nx2/build.pyexe_resources) or loaded (host/display.c).nx2/make_icon.py assets/longshot.png <folder>makes the same file byte for byte.Why
Players see the Hookshot icon on Longshot.
git show --stat e2a4d453listsbuilder/setup/{hookshot.ico => longshot.ico}with no size change, beside the newassets/longshot.png; nothing has touched the .ico since.tests/test_exe_icon.pychecked that the icon was well formed and linked, not which picture it held, so nothing failed.How to reproduce
Seen on: any Windows build since the rename, 3.0.0 included
Settings and switches: none
Steps: start the game and look at its window's icon and its taskbar button, or open
builder/setup/longshot.icoExpected: the green Longshot logo (
assets/longshot.png)Actual: the blue Hookshot icon
What changed
The icon file is made again from the logo, and the icon test now checks the picture as well as the file's form. No code changes.
builder/setup/longshot.ico: made again fromassets/longshot.png(python nx2/make_icon.py assets/longshot.png work, thenwork/longshot.icocopied here), the same sizes as before (16 to 256 pixels, PNG images).tests/test_exe_icon.py:check_picturedecodes the .ico's 32 and 256 pixel images andassets/longshot.png(a small PNG reader of its own: the builders that make releases have no Pillow), shrinks each to 16 by 16 and fails above a distance of 12, naming the command that makes the icon again. The new icon is at 7.8 and 1.7, the Hookshot icon at 35.Measurements
Verdict: nothing to measure: an image file, no code.
Flags and settings
None.
Testing
Tested:
python -I -B tests/test_exe_icon.py: fails on main ("the .ico's 32 pixel image is not assets/longshot.png (distance 35.2, above 12)") and passes here.The new .ico's 32 and 256 pixel images looked at: the green Longshot logo.
python nx2/make_icon.py assets/longshot.png <folder>with Pillow 13.0.0 writes this .ico byte for byte.python -I -B tests/run_all.py(Windows, the Builder's llvm-mingw): 690 passed, 41 failed, 125 skipped. Against main 868f6be8's 40, the one more istests/test_high_fps_fixes.py(test_music_manager_flags), which fails the same on main819a5967, this branch's base;tests/test_exe_icon.pypasses.Not tested: the icon in a running game's window and taskbar: the test reads back the .res the build links (icon group 1, every image of the .ico), which is what
host/display.cloads.Must be tested:
Risks
What could break: nothing that runs: the build links the same file under the same name.
Turning it off: revert the commit.
Compatibility: none: a build links the new icon; saves, settings and the translation are unchanged.
Checklist
Everyone
type(scope): description) of the status line's type.can't be run by hand is in Testing's Not testable by hand, with why.
in Risks.
main.python -I -B tests/run_all.pypasses (any failure that also fails onmainis named).third_party/untouched (a new folder with aPROVENANCE.mdinstead).When it applies
Assisted-by:/Co-Authored-By:trailers.mainand passing here.🤖 Generated with Claude Code
WIP: fix(build): the game's window and taskbar icon is Longshot's, not the old Hookshot oneto fix(build): the game's window and taskbar icon is Longshot's, not the old Hookshot one