WIP: feat(vk): choose the colour of Link's tunic in the Insert menu #1616

Draft
mooki wants to merge 7 commits from mooki/Longshot:feat/link-colours into main
Member

Type: feat · Risk: medium · Tested on: Linux, RTX 4090 (NVIDIA driver, windowless) · Needs: Windows, AMD

TL;DR

You can now pick the colour of Link's tunic and cap, child and adult, in the Insert menu (Gameplay, Link's colours): 24 named swatches, a picker or a hex code, applied while you pick, saved in your options file, and usable with a controller alone. Mido and the ocarina holder, who share Link's tunic texture in the game's files, keep their own green. Nothing from the game is added to the repository: the renderer finds Link's textures through a table the builder makes from your own game files. I checked it in the game on the build of this head, in five runs and a page run, and with new tests.

Breakdown

  • Who it helps: anyone who wants Link in another colour, playing alone; it is also the base the co-op look work needs (gear colours and other players seeing your colours are not in this PR).
  • What was wrong: nothing was wrong; the game has one fixed tunic colour, and because the game keeps one texture for each name, recolouring Link's tunic texture also recolours Mido and a prop that share it.
  • What changes: the renderer recolours Link's tunic textures as it uploads them, the builder makes the table that finds them and private copies for the two models that share them, and the menu gets the page, the option link_tunic and the variable HOS_LINK_TUNIC.
  • What does not change: with no colour chosen (the default) nothing is recoloured or copied; no shader, no pipeline, no renderer ABI; Link's models, the game's memory and the game's own files are never touched.
  • How it was checked: new game-free tests written first (each also shown failing on a deliberately broken copy), the whole suite against main by failing name, then the game on the full build of this head: the game on the full build of this head, five runs for the tunic (child, adult, three decode routes, the pause menu, Mido) and two for the page (a pad's A and B and the keyboard, then the saved colour at the next start), all exit 0 with no driver lines.
  • What is still open: Windows and AMD (nobody has run it there), a real controller's sticks and triggers (the host gives the menu only a digital mask), the ocarina holder's copy (not in view in the proof), and a live preview of Link while the page is open (the page covers the middle of the screen; Esc shows him).
  • Risk: medium: one lookup is added to the texture upload path and a mod folder to the game folder; both costs are measured below, and a game folder from before this change simply has neither.

Why

Link's tunic is always the same green. Players have asked to colour it, and a co-op project already does (https://github.com/daurosk/oot-remake-multiplayer), with ten fixed colours and a worker that polls the game's textures. This adds the first slice for Longshot: alone, any colour, with a page that works with a controller. No issue on the tracker asks for it (the tracker was searched: no cosmetics, palette, tunic or texture-override thread, open or closed).

What changed

The renderer recolours Link's tunic textures when it uploads them, from a table the builder makes from your own game files, so nothing from the game is in the source and the game's memory is never written. Mido and the ocarina holder get a texture of their own, made at build time, and stay green.

  • gpu/vk/coop_look_paint.{h,cpp} and tests/test_link_look_paint.cpp: daurosk's block recolour and test, GPL-3.0-or-later with his SPDX line, taken as they are from https://github.com/daurosk/oot-remake-multiplayer (commit 39b98de2); a test pins their hashes.
  • gpu/vk/link_look_recipes.h, link_look.{h,cpp}, link_look_upload.h, the seam in gpu/vk/vk_texture.cpp (look_begin(), guest_bytes(), upload_inner(), texture_touch(): about 40 lines) and vk_main.cpp: the recipe table, the choice, the recoloured copy laid over the guest's bytes for one upload on the CPU route, the live change (a texture made under an older choice is uploaded again at its next use), the copy kept per colour.
  • nx2/link_look_assets.py, nx2/make_game.py, nx2/prompt_assets.py: the builder writes look/recipes.txt and a mod folder mods/00-longshot-link-look (private copies of the two models and the one tile); the size-table row the new texture needs travels in prompts/rsizetable.zs, which host/prompts.c already merges into a mod's table.
  • gpu/vk/look_picker.h, vk_menu.{h,cpp}, menu_i18n.h, switches.def: the option link_tunic, the page (draw_look, look_open, look_close), the picker, 46 texts in the 13 menu languages (written by the assistant: a native speaker's look is welcome).
  • Docs: docs/link-colours.md, docs/link-colours-page.md, docs/development.md, the README's option table.

Not in this PR: gear colours, co-op (others seeing your colours), saved palettes and share codes, per-save colours, a rotating preview of Link.

Measurements

Verdict: works in the game on this PC; the cost is a one-time CPU recolour of about 85 ms for the child's five textures at load (93 ms for the adult's three, once per colour change) plus about 0.02 ms to look at each texture of a recipe's shape and size; no frame time is claimed (shared card).

Hardware: Linux (Arch, kernel 7.2.15), GeForce RTX 4090 with NVIDIA 615.78.08, Intel Core i9-13900K (32 threads), 93 GB; windowless, 1280x720 pictures.
Scene: Kokiri Forest, child, beside Mido; Kakariko, adult.
Method: the game's own longshot_log.txt lines "Link's colours" (a count and the milliseconds of each recolour and the running totals of hashing and recolouring) from the five games of the proof hold, analysis.txt made by a script from those logs.
How to reproduce: build a game folder, set HOS_LINK_TUNIC=1FA67A or open the page, look at Link.

Before: main @ 876dc3609 After: this PR @ 24ae0373a
Recolour at load, child (5 textures, once per start) not there 82.4, 84.1, 86.1, 100.6 and 130.2 ms in five starts (the 130 ms one had a second game running at the same time)
Recolour of the adult's 3 textures, per colour set not there 93.3 ms (teal) and 94.0 ms (red); the game's own colour costs nothing
Looking at a texture of a recipe's shape and size (a hash of its bytes), once per upload not there 1.9 ms for 106 textures, 5.7 ms for 311, 8.0 ms for 404 (about 0.02 ms each); 2.5 ms for 128 with no colour chosen
Live change, child (the page or the bridge), 5 textures not there 83.2 and 89.3 ms (two changes in one run); the largest single texture, the vest at 1536x1536, takes 42 to 69 ms
Memory not there up to 2.7 MiB of recoloured bytes kept (one copy for each of 7 recipes) and a scratch buffer of at most 4 MiB for each upload thread; no GPU memory is added
vk: Link's colours: 7 recipes from ~/Games/<game folder>/look/recipes.txt; the tunic is chosen
vk: Link's colours: Mt_PantsParts_Player_Child_Alb at 0x10d59dca00 (whole upload; NVN 0x46, ASTC 0, kept as BC 0, image VkFormat 133): #1fa67a, recoloured
vk: Link's colours:   3246 blocks changed in 1.3 ms
vk: Link's colours:   so far 11 textures hashed in 0.2 ms, 1 images recoloured in 1.3 ms
...
vk: Link's colours: Angin_Tile_A_Dark_Alb at 0x10d50a4400 (whole upload; NVN 0x88, ASTC 1, kept as BC 0, image VkFormat 37): #1fa67a, recoloured
vk: Link's colours:   17627 blocks changed in 22.5 ms
vk: Link's colours:   so far 106 textures hashed in 1.9 ms, 5 images recoloured in 130.2 ms

(from the child's first run, c1; the full lines are in the evidence folder of the run)

Flags and settings

An option, an environment name and a switch-table row; no renderer switch.

Flag What it is Before this PR After this PR Effect Helps / doesn't help / untested Recommendation
link_tunic (menu row Link's colours, ini key) the tunic's colour: RRGGBB or off not there off (the game's own) recolours Link's tunic textures at upload helps: the point of the PR the game's own by default
HOS_LINK_TUNIC=<RRGGBB> the colour for one run, over the file (off or empty: the game's own); row in gpu/vk/switches.def not there unset as above, for a scripted run proof runs for testing

Testing

Tested: on the PR head 24ae0373a rebased on main 876dc3609; the game runs below were made on a full nx2/make_game.py build of d21e02e95, the head's parent (the head adds one commit that changes only tests/test_upscaler_round_trip.py, which no game run reads). Linux, RTX 4090, windowless, 18 November 2026.

  • Game-free tests, written first: tests/test_link_look_paint.py (daurosk's recolour and his test, files pinned by hash), test_link_look_recipes.py (the table: good lines, comments, an unknown part, malformed and too long lines, the size window, a near miss), test_link_look_seam.py (the overlay is used only while an upload runs, guest memory is never written, an overlaid texture skips the GPU unswizzle, a new choice makes the textures again), test_link_look_assets.py (38 tests of the builder on a synthetic RomFS), test_link_look_picker.py (708 checks; the test breaks its subject 13 ways and each break fails one), test_link_look_menu.py (13 tests: the row, the page, the ini, the variable, the bridge, the translations), and the existing menu tests updated for the new row. All pass.
  • Whole suite, python -I -B tests/run_all.py: this head: 729 passed, 40 failed, 17 skipped; main 876dc3609: 722 passed, 41 failed, 17 skipped. All 40 failures of this head also fail on main (named in step 2); test_mods_size_table fails on main and passes here (its link stub now matches). One failure of my own was found this way (test_upscaler_round_trip, fixture out of date) and fixed in the head's last commit.
  • Windows-target syntax check on the head: all 14 of this PR's test drivers compile for Windows (llvm-mingw); four drivers I edited fail to compile with the same errors on plain main (test_astc_reuse, test_audio_output_menu, test_mods_size_table, test_stick_dead_zone: sources of main that Windows -Werror rejects). Windows execution was not run.
  • Game, hold 1 (five games, single, bridge driven): child beside Mido with teal from the first frame, then red, blue, the game's own and teal set live (link_tunic over the control bridge); adult in Kakariko, the game's own, then teal, red, the game's own; no colour chosen (the feature on); ASTC as RGBA8 (RX_VK_ASTC_RGBA8=1); ASTC on the CPU (RX_VK_ASTC_CPU=1). All five exit 0, kernel driver lines 0, no crash or device-lost line. The child's tunic and cap are recoloured (5 textures), the adult's tunic and cap (3); the pause menu's Equipment page shows Link in the colour; Mido's vest and cap stay green next to a teal Link; the three decode routes give the same colour.
  • Game, hold 4 (two games): the page opened with the keyboard through Insert, Gameplay, Link's colours; the pad's A (confirm) on Red, then on Gold, the pad's B (back) put the game's own colour back and closed the page, the page opened again, A on Red and Esc kept it: longshot_options.ini held link_tunic=C8321E afterwards, and the next start of the game came up with Link in red from the first frame, with no menu open.

How it was tested, step by step

  1. Tests first (Linux, game-free). For each new part the test was written and run before the code existed (it failed), then again with the code (it passed): the recolour and its test taken from daurosk's repository, the recipe table, the upload seam, the builder, the picker, the page. The picker's test also breaks its own subject 13 ways and each break is caught. Run through the workbench's no-core wrapper (https://github.com/mooki000/ls-workbench/tree/main/harness): python3 -I -B tests/test_link_look_<name>.py, the compile with -Wall -Wextra -Werror.
  2. Whole suite, branch against main. python -I -B tests/run_all.py --jobs 6 --strict once on main 876dc3609 and once on this head, under the whole-suite lock and the idle gate (a private wrapper that waits until the machine is quiet), compared by failing test name: 729 passed, 40 failed, 17 skipped on this head (277 s); 722 passed, 41 failed, 17 skipped on main (257 s). The failing names of this head, all also failing on main: test_bug_report_defaults, test_capture_readback_visibility, test_cpu_report, test_crt_options, test_damage_debug_menu, test_dev_packs, test_display_startup_failure, test_dlss_feature_size, test_draw_stream_visibility, test_failed_compile_keeps_objects, test_fsr_image_retirement, test_fsr_uniform_ownership, test_guest_imported, test_hud_layout_row, test_invalidate_quick, test_invalidate_vcore, test_libc_hooks, test_linux_preflight, test_linux_pressure, test_linux_update, test_log_open_failure, test_mirror_budget, test_missing_nup, test_nonuniform_image_arrays, test_parallel_init_order, test_pending_guest_import, test_pipeline_play_cache, test_present_source_crop, test_present_thread, test_profiling_mode, test_psychov35_fsr3_fg, test_readback_timeout_source, test_replay_write_order, test_run_all_changed, test_slow_frames, test_staging_burst, test_switch_table, test_upscaler_rows, test_vk_occlusion_queries, test_walk_key. On main only, test_mods_size_table also fails (it passes here: the test's link stub was brought up to date). The first branch run of the pair showed test_upscaler_round_trip failing only on the branch; that was mine (the fixture cut save() and menu_init() out of vk_menu.cpp without the new picker), fixed by the head's last commit, and this run is after it.
  3. Build. A full lift and compile of d21e02e95 with nx2/make_game.py (https://git.magicbean.dev/MagicBeanDev/Longshot/src/branch/main/nx2/make_game.py), through the full-build lock and the build gate: 611 s, exit 0, log line longshot v3.0.0-rc.7-88-gd21e02e95 (source 272919f8). The game folder has look/recipes.txt (7 lines, the builder's) and the mod folder mods/00-longshot-link-look (two model copies and one texture). Earlier heads were tried on a standalone nx2/build.py build (no lift) while this was written; none of that is evidence for this head and none is used here. Shader and pipeline caches were made once with the game's --prepare-shaders (295 s) before the games.
  4. Machine. Arch (Omarchy), kernel 7.2.15, GeForce RTX 4090 with NVIDIA 615.78.08, Core i9-13900K, 93 GB. Windowless (HOS_HEADLESS=1, https://git.magicbean.dev/MagicBeanDev/Longshot/src/branch/main/docs/development.md), through the GPU gate that lets games take turns, 1280x720 pictures. The machine was busy with other work (load average 12 to 54 during the runs), so no speed number is claimed.
  5. Saves and options. A kept test save with child Link in Kokiri Forest beside Mido and one with adult Link in Kakariko, copied by the run wrapper and never used in place. Each run got its own copy of an options file (HOS_OPTIONS_FILE) with link_tunic=off, because the control bridge's option set saves to the file it was started with.
  6. Driving the game. The control bridge (scripts/longshot_ctl.py, https://git.magicbean.dev/MagicBeanDev/Longshot/src/branch/main/docs/control.md) over a private socket per run: status until Link is controllable (state play, map and position), shot for a picture (the bridge's pictures leave the menu out and show Link as the game draws him), stick R to turn the camera, press PLUS and press L for the pause menu, option set link_tunic <value> for a live change, quit. The workbench's run wrapper starts the game, keeps the log, frame statistics and the kernel's driver lines, and says when the run ends. The public workbench has the same bridge calls as session tools: https://github.com/mooki000/ls-workbench.
  7. Hold 1, five games (a side-lane hold, one game at a time; the games are single and driven by the bridge): c1 child, teal from the first frame by HOS_LINK_TUNIC=1FA67A, four views, the pause menu's three pages, then red, blue, the game's own and teal set live, then a walk to Mido and a talk; a1 adult in Kakariko, the game's own, then teal, red and the game's own live; c0 child with no colour chosen (the feature on, the control picture); r2 child, teal, RX_VK_ASTC_RGBA8=1; r3 child, teal, RX_VK_ASTC_CPU=1. Pictures were taken at the same spot for each colour.
  8. Hold 4, two games (a main-lane hold, because a timed menu script is used): p1 child, RX_VK_MENU_SCRIPT presses Insert, the Gameplay tab, 14 times Down to Link's colours, Enter to open the page, Right and the pad's A (PADE, confirm) for Red, the pad's left button (PADW, Y: reset to the game's own, see step 10), two more Rights and A for Gold, the pad's B (PADS, back), Enter to open the page again, Right and A for Red, Esc (keep and close the page), Esc (close the menu); RX_VK_SHOT_MENU=1 and RX_VK_SHOT_EVERY=30 make the menu's own pictures every 30 presents (these show the page), and the bridge takes a picture of Link every 1.2 s and reads the option. p2 starts the game again on the options file p1 left, and sets the colour back to the game's own at its end.
  9. What the script's pad buttons are. The menu script's four tokens (PADS, PADE, PADW, PADN) inject only the menu's own confirm and back presses, so X, Y, the triggers, the sticks and L3 are not driven by any run here; the page's use of them is covered by the picker's state-machine test (708 checks) and by the page's own hint line, which the pictures show.
  10. A first try that was abandoned. The first try of hold 1 on this build counted the minutes two games waited at the GPU gate (7.5 and 3 minutes) against their own 200 s walls; those two runs never played, nothing was read from them, the script was changed to start a run's clock when the gate lets it in (and not to wait for the shader caches again), and all five games were run again from the start. An earlier hold on the previous standalone build showed that the script's pad tokens are the menu's confirm and back only, so the PADW press in this hold's timetable does nothing: the pictures show Red staying Red until the next A. I left it in the timetable and say so instead of counting a reset as tested.
  11. Reading. Every picture was looked at, panels were made from them with a small script (panels.sh of the evidence skill), and the log lines were counted by a script (analyze1.py): per run, the textures recoloured and by which colour, the milliseconds, the mods loaded (Mido's and the ocarina holder's copies), and the fatal, crash and device-lost counts (all 0).
  12. The CPU decode route. The first picture of r3 is entirely black. A control run without the feature on an earlier build (the spike) had the same black first picture, and r3's other three pictures show Link and his shield as expected. I attribute the black picture to that diagnostic route being slow to draw its first frames, not to this change; I did not run another control on this head.
  13. Not run. Windows, AMD, a real controller's X, Y, triggers, sticks and L3, the ocarina holder in view, a character mod that replaces Link's textures, any speed measurement.

Pictures

Child Link in teal #1FA67A from the first frame, behind, from both sides and the front (hold 1, run c1)
The same spot, changed while playing: red, blue, the game's own, teal (hold 1, run c1)
Mido, with no colour chosen and with Link in teal (Link's cap at the bottom): his clothes are the same
The pause menu: the Equipment page shows Link in the colour (the tunic's icon is a menu texture and stays green)
Adult Link in Kakariko: the game's own, teal, red, the game's own again
The same teal on the default route, with ASTC as RGBA8 and with ASTC on the CPU, next to no colour chosen
The page driven by a pad's A and B: the game's own, Red (A), Gold (A again), then B closes the page and the game's own is back
Link while that ran (the bridge's pictures, no menu): before, Red, Gold, cancelled, kept; Mido at the top stays green in all five

Not testable by hand: a real controller's X (compare), Y (reset), triggers (turn the hue) and L3 (the D-pad in the square): the host gives the menu only a digital mask of the pad's buttons, the control bridge's press goes to the game and not to the menu, and the menu script's pad tokens inject only the menu's confirm and back. Those paths are covered by the picker's state-machine test (708 checks, 13 deliberate breaks) and, in the game, only A and B were driven. A person with a controller can try the rest.

Not tested: Windows and AMD; the ocarina holder's copy (not in view in any picture, only its loading is in the log); a character mod that replaces Link's textures or models; frame times (shared card, no timing claim is made); the black first picture on the CPU ASTC diagnostic route was not run down (step 12 below).

Must be tested:

  • Windows, any GPU: build, open Gameplay, Link's colours, pick a colour, then look at Link and Mido; expecting the tunic in the colour and Mido green (Test Farm: @Beanstalk windows, Link's colours page)
  • Linux, AMD (RADV): the same, expecting the same colour on the ASTC route AMD uses (Test Farm: @Beanstalk radv)
  • Any controller: open Insert, Gameplay, Link's colours with the pad; the D-pad moves the cursor, A uses a swatch, B cancels and closes, X held shows the game's own colours, Y resets, LT and RT turn the hue, L3 moves the D-pad into the square, Start keeps; expecting each as docs/link-colours-page.md says (Test Farm: any player with a controller)

Risks

What could break: the upload path of every texture gets one lookup (link_look::wanted, a table of seven entries): a texture of a recipe's shape and size is hashed once (PENDING:cost-hash-short). A mod that replaces Link's textures makes the table match nothing and the page says "not found in this game". The private copies need the game to take a texture under a new name from the mod folder with a size-table row: it did in the proof (the log shows both files loaded, no hang), but a user mod whose own size table cannot be merged by host/prompts.c loses our row (Mido and the holder would then follow Link's colour or fail to load; not seen). On the CPU ASTC diagnostic route a texture can be black at the moment of a picture; it happened without the feature too (see the step list).

Turning it off: the game's own colour is the default and the lookup does nothing without look/recipes.txt; reverting the commits removes everything.

Compatibility: longshot_options.ini gets one new key; the builder writes look/ and a mod folder in the game folder (a build from before this has neither and nothing changes); prompts/rsizetable.zs is written even when the font needs no raise; the shader translator and the pipeline caches are not touched; no MKWVK_API_VERSION change.

Checklist

Everyone

  • One topic.
  • The title is a Conventional Commit (type(scope): description) of the status line's type.
  • Why gives the reason plainly and links the issues that fit (the tracker searched).
  • Tested on my own PC where it runs (in the game, for a change the game runs), as Testing's Tested says; what
    can't be run by hand is in Testing's Not testable by hand, with why.
  • Measurements has a verdict, or one line saying why there is nothing to measure.
  • Nothing gets worse that I know of: any cost (speed, latency, memory, a setup that worked before) is measured and
    in Risks.
  • Testing names what was tested, what wasn't, and what must still be tested, where and how.
  • Rebased on current main.
  • python -I -B tests/run_all.py passes (any failure that also fails on main is named).
  • No game files, dumps, build output or generated files.
  • third_party/ untouched (a new folder with a PROVENANCE.md instead).
  • The license is OK: GPL-3.0-or-later, nothing incompatible and nothing decompiled.

When it applies

  • AI assistance recorded with Assisted-by: / Co-Authored-By: trailers.
  • Switches documented (docs/development.md; the README for a menu row) and shipped at their recommended value.
  • Screenshots of the same spot, captioned like the Measurements columns, for a change that shows on screen.
  • A game-free test added for the fix, failing on main and passing here.
  • A check under tests/ that reads changed source updated in this PR, not weakened.
  • Host code builds on both Windows (llvm-mingw) and Linux, with UTF-8 paths.
  • Docs updated.

New on this forge; not opened on GitHub.

**Type:** feat · **Risk:** medium · **Tested on:** Linux, RTX 4090 (NVIDIA driver, windowless) · **Needs:** Windows, AMD ## TL;DR You can now pick the colour of Link's tunic and cap, child and adult, in the Insert menu (Gameplay, Link's colours): 24 named swatches, a picker or a hex code, applied while you pick, saved in your options file, and usable with a controller alone. Mido and the ocarina holder, who share Link's tunic texture in the game's files, keep their own green. Nothing from the game is added to the repository: the renderer finds Link's textures through a table the builder makes from your own game files. I checked it in the game on the build of this head, in five runs and a page run, and with new tests. ## Breakdown - **Who it helps:** anyone who wants Link in another colour, playing alone; it is also the base the co-op look work needs (gear colours and other players seeing your colours are not in this PR). - **What was wrong:** nothing was wrong; the game has one fixed tunic colour, and because the game keeps one texture for each name, recolouring Link's tunic texture also recolours Mido and a prop that share it. - **What changes:** the renderer recolours Link's tunic textures as it uploads them, the builder makes the table that finds them and private copies for the two models that share them, and the menu gets the page, the option `link_tunic` and the variable `HOS_LINK_TUNIC`. - **What does not change:** with no colour chosen (the default) nothing is recoloured or copied; no shader, no pipeline, no renderer ABI; Link's models, the game's memory and the game's own files are never touched. - **How it was checked:** new game-free tests written first (each also shown failing on a deliberately broken copy), the whole suite against main by failing name, then the game on the full build of this head: the game on the full build of this head, five runs for the tunic (child, adult, three decode routes, the pause menu, Mido) and two for the page (a pad's A and B and the keyboard, then the saved colour at the next start), all exit 0 with no driver lines. - **What is still open:** Windows and AMD (nobody has run it there), a real controller's sticks and triggers (the host gives the menu only a digital mask), the ocarina holder's copy (not in view in the proof), and a live preview of Link while the page is open (the page covers the middle of the screen; Esc shows him). - **Risk:** medium: one lookup is added to the texture upload path and a mod folder to the game folder; both costs are measured below, and a game folder from before this change simply has neither. ## Why Link's tunic is always the same green. Players have asked to colour it, and a co-op project already does (https://github.com/daurosk/oot-remake-multiplayer), with ten fixed colours and a worker that polls the game's textures. This adds the first slice for Longshot: alone, any colour, with a page that works with a controller. No issue on the tracker asks for it (the tracker was searched: no cosmetics, palette, tunic or texture-override thread, open or closed). ## What changed The renderer recolours Link's tunic textures when it uploads them, from a table the builder makes from your own game files, so nothing from the game is in the source and the game's memory is never written. Mido and the ocarina holder get a texture of their own, made at build time, and stay green. - `gpu/vk/coop_look_paint.{h,cpp}` and `tests/test_link_look_paint.cpp`: daurosk's block recolour and test, GPL-3.0-or-later with his SPDX line, taken as they are from https://github.com/daurosk/oot-remake-multiplayer (commit `39b98de2`); a test pins their hashes. - `gpu/vk/link_look_recipes.h`, `link_look.{h,cpp}`, `link_look_upload.h`, the seam in `gpu/vk/vk_texture.cpp` (`look_begin()`, `guest_bytes()`, `upload_inner()`, `texture_touch()`: about 40 lines) and `vk_main.cpp`: the recipe table, the choice, the recoloured copy laid over the guest's bytes for one upload on the CPU route, the live change (a texture made under an older choice is uploaded again at its next use), the copy kept per colour. - `nx2/link_look_assets.py`, `nx2/make_game.py`, `nx2/prompt_assets.py`: the builder writes `look/recipes.txt` and a mod folder `mods/00-longshot-link-look` (private copies of the two models and the one tile); the size-table row the new texture needs travels in `prompts/rsizetable.zs`, which `host/prompts.c` already merges into a mod's table. - `gpu/vk/look_picker.h`, `vk_menu.{h,cpp}`, `menu_i18n.h`, `switches.def`: the option `link_tunic`, the page (`draw_look`, `look_open`, `look_close`), the picker, 46 texts in the 13 menu languages (written by the assistant: a native speaker's look is welcome). - Docs: `docs/link-colours.md`, `docs/link-colours-page.md`, `docs/development.md`, the README's option table. **Not in this PR:** gear colours, co-op (others seeing your colours), saved palettes and share codes, per-save colours, a rotating preview of Link. ## Measurements **Verdict:** works in the game on this PC; the cost is a one-time CPU recolour of about 85 ms for the child's five textures at load (93 ms for the adult's three, once per colour change) plus about 0.02 ms to look at each texture of a recipe's shape and size; no frame time is claimed (shared card). Hardware: Linux (Arch, kernel 7.2.15), GeForce RTX 4090 with NVIDIA 615.78.08, Intel Core i9-13900K (32 threads), 93 GB; windowless, 1280x720 pictures. Scene: Kokiri Forest, child, beside Mido; Kakariko, adult. Method: the game's own `longshot_log.txt` lines "Link's colours" (a count and the milliseconds of each recolour and the running totals of hashing and recolouring) from the five games of the proof hold, `analysis.txt` made by a script from those logs. How to reproduce: build a game folder, set `HOS_LINK_TUNIC=1FA67A` or open the page, look at Link. | | Before: main @ 876dc3609 | After: this PR @ 24ae0373a | |---|---|---| | Recolour at load, child (5 textures, once per start) | not there | 82.4, 84.1, 86.1, 100.6 and 130.2 ms in five starts (the 130 ms one had a second game running at the same time) | | Recolour of the adult's 3 textures, per colour set | not there | 93.3 ms (teal) and 94.0 ms (red); the game's own colour costs nothing | | Looking at a texture of a recipe's shape and size (a hash of its bytes), once per upload | not there | 1.9 ms for 106 textures, 5.7 ms for 311, 8.0 ms for 404 (about 0.02 ms each); 2.5 ms for 128 with no colour chosen | | Live change, child (the page or the bridge), 5 textures | not there | 83.2 and 89.3 ms (two changes in one run); the largest single texture, the vest at 1536x1536, takes 42 to 69 ms | | Memory | not there | up to 2.7 MiB of recoloured bytes kept (one copy for each of 7 recipes) and a scratch buffer of at most 4 MiB for each upload thread; no GPU memory is added | ``` vk: Link's colours: 7 recipes from ~/Games/<game folder>/look/recipes.txt; the tunic is chosen vk: Link's colours: Mt_PantsParts_Player_Child_Alb at 0x10d59dca00 (whole upload; NVN 0x46, ASTC 0, kept as BC 0, image VkFormat 133): #1fa67a, recoloured vk: Link's colours: 3246 blocks changed in 1.3 ms vk: Link's colours: so far 11 textures hashed in 0.2 ms, 1 images recoloured in 1.3 ms ... vk: Link's colours: Angin_Tile_A_Dark_Alb at 0x10d50a4400 (whole upload; NVN 0x88, ASTC 1, kept as BC 0, image VkFormat 37): #1fa67a, recoloured vk: Link's colours: 17627 blocks changed in 22.5 ms vk: Link's colours: so far 106 textures hashed in 1.9 ms, 5 images recoloured in 130.2 ms ``` (from the child's first run, c1; the full lines are in the evidence folder of the run) ### Flags and settings An option, an environment name and a switch-table row; no renderer switch. | Flag | What it is | Before this PR | After this PR | Effect | Helps / doesn't help / untested | Recommendation | |---|---|---|---|---|---|---| | `link_tunic` (menu row Link's colours, ini key) | the tunic's colour: `RRGGBB` or `off` | not there | `off` (the game's own) | recolours Link's tunic textures at upload | helps: the point of the PR | the game's own by default | | `HOS_LINK_TUNIC=<RRGGBB>` | the colour for one run, over the file (`off` or empty: the game's own); row in `gpu/vk/switches.def` | not there | unset | as above, for a scripted run | proof runs | for testing | ## Testing **Tested:** on the PR head `24ae0373a` rebased on `main` `876dc3609`; the game runs below were made on a full `nx2/make_game.py` build of `d21e02e95`, the head's parent (the head adds one commit that changes only `tests/test_upscaler_round_trip.py`, which no game run reads). Linux, RTX 4090, windowless, 18 November 2026. - Game-free tests, written first: `tests/test_link_look_paint.py` (daurosk's recolour and his test, files pinned by hash), `test_link_look_recipes.py` (the table: good lines, comments, an unknown part, malformed and too long lines, the size window, a near miss), `test_link_look_seam.py` (the overlay is used only while an upload runs, guest memory is never written, an overlaid texture skips the GPU unswizzle, a new choice makes the textures again), `test_link_look_assets.py` (38 tests of the builder on a synthetic RomFS), `test_link_look_picker.py` (708 checks; the test breaks its subject 13 ways and each break fails one), `test_link_look_menu.py` (13 tests: the row, the page, the ini, the variable, the bridge, the translations), and the existing menu tests updated for the new row. All pass. - Whole suite, `python -I -B tests/run_all.py`: this head: 729 passed, 40 failed, 17 skipped; `main` `876dc3609`: 722 passed, 41 failed, 17 skipped. All 40 failures of this head also fail on `main` (named in step 2); `test_mods_size_table` fails on `main` and passes here (its link stub now matches). One failure of my own was found this way (`test_upscaler_round_trip`, fixture out of date) and fixed in the head's last commit. - Windows-target syntax check on the head: all 14 of this PR's test drivers compile for Windows (llvm-mingw); four drivers I edited fail to compile with the same errors on plain `main` (`test_astc_reuse`, `test_audio_output_menu`, `test_mods_size_table`, `test_stick_dead_zone`: sources of `main` that Windows `-Werror` rejects). Windows execution was not run. - Game, hold 1 (five games, single, bridge driven): child beside Mido with teal from the first frame, then red, blue, the game's own and teal set live (`link_tunic` over the control bridge); adult in Kakariko, the game's own, then teal, red, the game's own; no colour chosen (the feature on); ASTC as RGBA8 (`RX_VK_ASTC_RGBA8=1`); ASTC on the CPU (`RX_VK_ASTC_CPU=1`). All five exit 0, kernel driver lines 0, no crash or device-lost line. The child's tunic and cap are recoloured (5 textures), the adult's tunic and cap (3); the pause menu's Equipment page shows Link in the colour; Mido's vest and cap stay green next to a teal Link; the three decode routes give the same colour. - Game, hold 4 (two games): the page opened with the keyboard through Insert, Gameplay, Link's colours; the pad's A (confirm) on Red, then on Gold, the pad's B (back) put the game's own colour back and closed the page, the page opened again, A on Red and Esc kept it: `longshot_options.ini` held `link_tunic=C8321E` afterwards, and the next start of the game came up with Link in red from the first frame, with no menu open. ### How it was tested, step by step 1. **Tests first (Linux, game-free).** For each new part the test was written and run before the code existed (it failed), then again with the code (it passed): the recolour and its test taken from daurosk's repository, the recipe table, the upload seam, the builder, the picker, the page. The picker's test also breaks its own subject 13 ways and each break is caught. Run through the workbench's no-core wrapper (https://github.com/mooki000/ls-workbench/tree/main/harness): `python3 -I -B tests/test_link_look_<name>.py`, the compile with `-Wall -Wextra -Werror`. 2. **Whole suite, branch against `main`.** `python -I -B tests/run_all.py --jobs 6 --strict` once on `main` 876dc3609 and once on this head, under the whole-suite lock and the idle gate (a private wrapper that waits until the machine is quiet), compared by failing test name: 729 passed, 40 failed, 17 skipped on this head (277 s); 722 passed, 41 failed, 17 skipped on `main` (257 s). The failing names of this head, all also failing on `main`: `test_bug_report_defaults`, `test_capture_readback_visibility`, `test_cpu_report`, `test_crt_options`, `test_damage_debug_menu`, `test_dev_packs`, `test_display_startup_failure`, `test_dlss_feature_size`, `test_draw_stream_visibility`, `test_failed_compile_keeps_objects`, `test_fsr_image_retirement`, `test_fsr_uniform_ownership`, `test_guest_imported`, `test_hud_layout_row`, `test_invalidate_quick`, `test_invalidate_vcore`, `test_libc_hooks`, `test_linux_preflight`, `test_linux_pressure`, `test_linux_update`, `test_log_open_failure`, `test_mirror_budget`, `test_missing_nup`, `test_nonuniform_image_arrays`, `test_parallel_init_order`, `test_pending_guest_import`, `test_pipeline_play_cache`, `test_present_source_crop`, `test_present_thread`, `test_profiling_mode`, `test_psychov35_fsr3_fg`, `test_readback_timeout_source`, `test_replay_write_order`, `test_run_all_changed`, `test_slow_frames`, `test_staging_burst`, `test_switch_table`, `test_upscaler_rows`, `test_vk_occlusion_queries`, `test_walk_key`. On `main` only, `test_mods_size_table` also fails (it passes here: the test's link stub was brought up to date). The first branch run of the pair showed `test_upscaler_round_trip` failing only on the branch; that was mine (the fixture cut `save()` and `menu_init()` out of `vk_menu.cpp` without the new picker), fixed by the head's last commit, and this run is after it. 3. **Build.** A full lift and compile of `d21e02e95` with `nx2/make_game.py` (https://git.magicbean.dev/MagicBeanDev/Longshot/src/branch/main/nx2/make_game.py), through the full-build lock and the build gate: 611 s, exit 0, log line `longshot v3.0.0-rc.7-88-gd21e02e95 (source 272919f8)`. The game folder has `look/recipes.txt` (7 lines, the builder's) and the mod folder `mods/00-longshot-link-look` (two model copies and one texture). Earlier heads were tried on a standalone `nx2/build.py` build (no lift) while this was written; none of that is evidence for this head and none is used here. Shader and pipeline caches were made once with the game's `--prepare-shaders` (295 s) before the games. 4. **Machine.** Arch (Omarchy), kernel 7.2.15, GeForce RTX 4090 with NVIDIA 615.78.08, Core i9-13900K, 93 GB. Windowless (`HOS_HEADLESS=1`, https://git.magicbean.dev/MagicBeanDev/Longshot/src/branch/main/docs/development.md), through the GPU gate that lets games take turns, 1280x720 pictures. The machine was busy with other work (load average 12 to 54 during the runs), so no speed number is claimed. 5. **Saves and options.** A kept test save with child Link in Kokiri Forest beside Mido and one with adult Link in Kakariko, copied by the run wrapper and never used in place. Each run got its own copy of an options file (`HOS_OPTIONS_FILE`) with `link_tunic=off`, because the control bridge's `option set` saves to the file it was started with. 6. **Driving the game.** The control bridge (`scripts/longshot_ctl.py`, https://git.magicbean.dev/MagicBeanDev/Longshot/src/branch/main/docs/control.md) over a private socket per run: `status` until Link is controllable (state `play`, map and position), `shot` for a picture (the bridge's pictures leave the menu out and show Link as the game draws him), `stick R` to turn the camera, `press PLUS` and `press L` for the pause menu, `option set link_tunic <value>` for a live change, `quit`. The workbench's run wrapper starts the game, keeps the log, frame statistics and the kernel's driver lines, and says when the run ends. The public workbench has the same bridge calls as session tools: https://github.com/mooki000/ls-workbench. 7. **Hold 1, five games** (a side-lane hold, one game at a time; the games are single and driven by the bridge): c1 child, teal from the first frame by `HOS_LINK_TUNIC=1FA67A`, four views, the pause menu's three pages, then red, blue, the game's own and teal set live, then a walk to Mido and a talk; a1 adult in Kakariko, the game's own, then teal, red and the game's own live; c0 child with no colour chosen (the feature on, the control picture); r2 child, teal, `RX_VK_ASTC_RGBA8=1`; r3 child, teal, `RX_VK_ASTC_CPU=1`. Pictures were taken at the same spot for each colour. 8. **Hold 4, two games** (a main-lane hold, because a timed menu script is used): p1 child, `RX_VK_MENU_SCRIPT` presses Insert, the Gameplay tab, 14 times Down to Link's colours, Enter to open the page, Right and the pad's A (`PADE`, confirm) for Red, the pad's left button (`PADW`, Y: reset to the game's own, see step 10), two more Rights and A for Gold, the pad's B (`PADS`, back), Enter to open the page again, Right and A for Red, Esc (keep and close the page), Esc (close the menu); `RX_VK_SHOT_MENU=1` and `RX_VK_SHOT_EVERY=30` make the menu's own pictures every 30 presents (these show the page), and the bridge takes a picture of Link every 1.2 s and reads the option. p2 starts the game again on the options file p1 left, and sets the colour back to the game's own at its end. 9. **What the script's pad buttons are.** The menu script's four tokens (`PADS`, `PADE`, `PADW`, `PADN`) inject only the menu's own confirm and back presses, so X, Y, the triggers, the sticks and L3 are not driven by any run here; the page's use of them is covered by the picker's state-machine test (708 checks) and by the page's own hint line, which the pictures show. 10. **A first try that was abandoned.** The first try of hold 1 on this build counted the minutes two games waited at the GPU gate (7.5 and 3 minutes) against their own 200 s walls; those two runs never played, nothing was read from them, the script was changed to start a run's clock when the gate lets it in (and not to wait for the shader caches again), and all five games were run again from the start. An earlier hold on the previous standalone build showed that the script's pad tokens are the menu's confirm and back only, so the `PADW` press in this hold's timetable does nothing: the pictures show Red staying Red until the next A. I left it in the timetable and say so instead of counting a reset as tested. 11. **Reading.** Every picture was looked at, panels were made from them with a small script (`panels.sh` of the evidence skill), and the log lines were counted by a script (`analyze1.py`): per run, the textures recoloured and by which colour, the milliseconds, the mods loaded (Mido's and the ocarina holder's copies), and the fatal, crash and device-lost counts (all 0). 12. **The CPU decode route.** The first picture of r3 is entirely black. A control run without the feature on an earlier build (the spike) had the same black first picture, and r3's other three pictures show Link and his shield as expected. I attribute the black picture to that diagnostic route being slow to draw its first frames, not to this change; I did not run another control on this head. 13. **Not run.** Windows, AMD, a real controller's X, Y, triggers, sticks and L3, the ocarina holder in view, a character mod that replaces Link's textures, any speed measurement. ### Pictures ![Child Link in teal #1FA67A from the first frame, behind, from both sides and the front (hold 1, run c1)](https://git.magicbean.dev/attachments/27513c4a-24c9-4789-83a7-340ccbbb8e62) ![The same spot, changed while playing: red, blue, the game's own, teal (hold 1, run c1)](https://git.magicbean.dev/attachments/3b965641-296f-467f-9b46-c119df7694bf) ![Mido, with no colour chosen and with Link in teal (Link's cap at the bottom): his clothes are the same](https://git.magicbean.dev/attachments/582eec90-f5bb-4037-9869-83e93137453b) ![The pause menu: the Equipment page shows Link in the colour (the tunic's icon is a menu texture and stays green)](https://git.magicbean.dev/attachments/49c3ee55-fee5-48a4-ab96-12ea64169226) ![Adult Link in Kakariko: the game's own, teal, red, the game's own again](https://git.magicbean.dev/attachments/ce3119f1-0011-4d30-b09e-da7b3ce8b08c) ![The same teal on the default route, with ASTC as RGBA8 and with ASTC on the CPU, next to no colour chosen](https://git.magicbean.dev/attachments/abd99305-19e2-4ba8-9382-9f6fd877cb3f) ![The page driven by a pad's A and B: the game's own, Red (A), Gold (A again), then B closes the page and the game's own is back](https://git.magicbean.dev/attachments/20dc2c78-1175-494c-9912-281325bbb9ee) ![Link while that ran (the bridge's pictures, no menu): before, Red, Gold, cancelled, kept; Mido at the top stays green in all five](https://git.magicbean.dev/attachments/5c265fff-bdd3-4474-abc5-604658fd494e) **Not testable by hand:** a real controller's X (compare), Y (reset), triggers (turn the hue) and L3 (the D-pad in the square): the host gives the menu only a digital mask of the pad's buttons, the control bridge's `press` goes to the game and not to the menu, and the menu script's pad tokens inject only the menu's confirm and back. Those paths are covered by the picker's state-machine test (708 checks, 13 deliberate breaks) and, in the game, only A and B were driven. A person with a controller can try the rest. **Not tested:** Windows and AMD; the ocarina holder's copy (not in view in any picture, only its loading is in the log); a character mod that replaces Link's textures or models; frame times (shared card, no timing claim is made); the black first picture on the CPU ASTC diagnostic route was not run down (step 12 below). **Must be tested:** - Windows, any GPU: build, open Gameplay, Link's colours, pick a colour, then look at Link and Mido; expecting the tunic in the colour and Mido green (Test Farm: `@Beanstalk windows`, Link's colours page) - Linux, AMD (RADV): the same, expecting the same colour on the ASTC route AMD uses (Test Farm: `@Beanstalk radv`) - Any controller: open Insert, Gameplay, Link's colours with the pad; the D-pad moves the cursor, A uses a swatch, B cancels and closes, X held shows the game's own colours, Y resets, LT and RT turn the hue, L3 moves the D-pad into the square, Start keeps; expecting each as `docs/link-colours-page.md` says (Test Farm: any player with a controller) ## Risks **What could break:** the upload path of every texture gets one lookup (`link_look::wanted`, a table of seven entries): a texture of a recipe's shape and size is hashed once (PENDING:cost-hash-short). A mod that replaces Link's textures makes the table match nothing and the page says "not found in this game". The private copies need the game to take a texture under a new name from the mod folder with a size-table row: it did in the proof (the log shows both files loaded, no hang), but a user mod whose own size table cannot be merged by `host/prompts.c` loses our row (Mido and the holder would then follow Link's colour or fail to load; not seen). On the CPU ASTC diagnostic route a texture can be black at the moment of a picture; it happened without the feature too (see the step list). **Turning it off:** the game's own colour is the default and the lookup does nothing without `look/recipes.txt`; reverting the commits removes everything. **Compatibility:** `longshot_options.ini` gets one new key; the builder writes `look/` and a mod folder in the game folder (a build from before this has neither and nothing changes); `prompts/rsizetable.zs` is written even when the font needs no raise; the shader translator and the pipeline caches are not touched; no `MKWVK_API_VERSION` change. ## Checklist ### Everyone - [x] One topic. - [x] The title is a Conventional Commit (`type(scope): description`) of the status line's type. - [x] Why gives the reason plainly and links the issues that fit (the tracker searched). - [x] Tested on my own PC where it runs (in the game, for a change the game runs), as Testing's Tested says; what can't be run by hand is in Testing's Not testable by hand, with why. - [x] Measurements has a verdict, or one line saying why there is nothing to measure. - [x] Nothing gets worse that I know of: any cost (speed, latency, memory, a setup that worked before) is measured and in Risks. - [x] Testing names what was tested, what wasn't, and what must still be tested, where and how. - [x] Rebased on current `main`. - [x] `python -I -B tests/run_all.py` passes (any failure that also fails on `main` is named). - [x] No game files, dumps, build output or generated files. - [x] `third_party/` untouched (a new folder with a `PROVENANCE.md` instead). - [x] The license is OK: GPL-3.0-or-later, nothing incompatible and nothing decompiled. ### When it applies - [x] AI assistance recorded with `Assisted-by:` / `Co-Authored-By:` trailers. - [x] Switches documented (docs/development.md; the README for a menu row) and shipped at their recommended value. - [x] Screenshots of the same spot, captioned like the Measurements columns, for a change that shows on screen. - [x] A game-free test added for the fix, failing on `main` and passing here. - [x] A check under `tests/` that reads changed source updated in this PR, not weakened. - [ ] Host code builds on both Windows (llvm-mingw) and Linux, with UTF-8 paths. - [x] Docs updated. --- New on this forge; not opened on GitHub.
gpu/vk/coop_look_paint.{h,cpp} recolour the end colours of BC1, BC3 and ASTC blocks of one tone to another colour without decoding the texture, keeping
the shading. They are taken as they are from https://github.com/daurosk/oot-remake-multiplayer (hookshot/src, commit 39b98de2), GPL-3.0-or-later with his
SPDX line, and tests/test_link_look_paint.cpp carries his look_paint_test.cpp (the checks and the synthetic golden blocks are his; his doctest macros are
replaced by a small shim). tests/test_link_look_paint.py pins the two files by hash so an edit of them is a decision.

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Co-authored-by: daurosk <[email protected]>
gpu/vk/link_look_recipes.h reads look/recipes.txt, the table the builder will write from the player's own files: one line for each texture of Link's tunic
that can be recoloured (the hash of its image, its sizes, its format, the tones that change). A line that does not read is skipped and said, a part this build
does not know is skipped, a file of another version is refused. Nothing from the game is in the source.

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
When a texture is uploaded whose image is one of the table's (link_look_upload.h), the renderer lays a recoloured copy of its bytes over the guest's for that one
upload (vk_texture.cpp guest_bytes), so the game's memory is never written: the copy goes through the CPU route (no GPU unswizzle, no all-zero clear), is never
listed for reuse, and the recolour is daurosk's block code (the overlay and that route rule are the idea of his patch 0020, rewritten). The choice of colour
(link_look.h: tunic, set_tunic, available, generation) is one word with its generation, so a change makes the textures again at their next use and the game's own
colour gives back exactly the game's bytes. The recoloured copy of a texture is kept for the choice it was made for: a scene entered again does not paint again.

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Co-authored-by: daurosk <[email protected]>
nx2/link_look_assets.py reads the player's own files at build time and writes, beside the game's files and never into them: look/recipes.txt (one line for each
texture of Link's tunic the renderer can recolour: the hash of its image, its sizes, its format and the tones that change; gpu/vk/link_look_recipes.h reads it),
and a mod folder mods/00-longshot-link-look/romfs with a private copy of each model that shares Link's tunic tile without being Link's (Mido and the ocarina
holder: the whole RomFS was scanned for the exact name) and of the tile itself, differing in one letter of the name and one marked byte of the image, so those
models stay in the game's colours when Link's change. Link's own models, his tunic items and the cap prop are not copied: they follow his colour.

The size table row the new texture file needs goes into prompts/rsizetable.zs (nx2/prompt_assets.py --extra-sizes; the host already merges that table into a mod's
own, host/prompts.c), which is now written whenever such rows exist. make_game.py runs the step before the prompts, never fails the build for it, and takes the
copies away when the prompts were not made. tests/test_mods_size_table.py gets the three cases of the row (no mod table, a later one, an earlier one) and the
stub its routing half had lacked since the options file moved (undefined reference to hos_options_file on main).

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
A "Link's colours" row on the Gameplay tab opens a page with a swatch grid of 24 colours (the game's own, then named ones), an HSV picker, a hex box, reset,
X held to compare with the game's own, and a warning for a colour too dark or too bright; the colour applies while it is picked (at most every 125 ms while
dragging, the last one at once), B cancels back to the colour from before and Esc, Start or closing the menu keep it. Everything works with the pad's digital
buttons (the host gives the menu no analog sticks), the mouse and the keyboard. look_picker.h holds the colour maths and the picker's state machine with no
ImGui in it, so a test drives it.

The choice is the option link_tunic: -1 the game's own, else 0xRRGGBB; longshot_options.ini keeps it as RRGGBB or off (a value that does not read is off),
HOS_LINK_TUNIC sets it for one run, the control bridge's option set changes it while the game runs, and menu_init gives it to the renderer (link_look.h). The page's
texts are in the 13 languages of the menu; a line says when the game folder has no recipe table (not found in this game).

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
docs/link-colours.md says how the renderer recolours the tunic's textures at upload, what the builder makes, the log lines and the limits, with the credit to
daurosk's block recolour; docs/link-colours-page.md is for players (the page and its controls); docs/development.md names link_tunic and HOS_LINK_TUNIC.

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
test(menu): the upscaler round trip's fixture knows the Link's colours row
Some checks failed
CI / Python source checks (ubuntu-24.04, part 1/2) (pull_request) Has been skipped
CI / Python source checks (ubuntu-24.04, part 2/2) (pull_request) Has been skipped
CI / SPIR-V fixtures (global narrow load/store, direct surface atomics, F2I immediate) (pull_request) Has been skipped
Third-party parts / The same as upstream (pull_request) Has been skipped
Website / Website on Cloudflare (pull_request) Has been skipped
Website / Website on Cloudflare (pull_request_target) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 12s
Guide screenshots / Guide images and local UI source review (pull_request) Failing after 19s
CI / Workflow lint (actionlint) (pull_request) Successful in 19s
Third-party parts / As their notes say (pull_request) Successful in 21s
PR description / Description follows the template (pull_request_target) Successful in 10s
24ae0373a9
test_upscaler_round_trip cuts save(), menu_init() and menu_setting_set() out of vk_menu.cpp; they now read and write the Link's colours option through look_picker.h
and tell the page's side (link_tunic_set), so the fixture includes look_picker.h and stubs link_tunic_set. Found by the whole suite against main: it failed only on the branch.

Assisted-by: Claude Sonnet 5.5
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Some checks failed
CI / Python source checks (ubuntu-24.04, part 1/2) (pull_request) Has been skipped
CI / Python source checks (ubuntu-24.04, part 2/2) (pull_request) Has been skipped
CI / SPIR-V fixtures (global narrow load/store, direct surface atomics, F2I immediate) (pull_request) Has been skipped
Third-party parts / The same as upstream (pull_request) Has been skipped
Website / Website on Cloudflare (pull_request) Has been skipped
Website / Website on Cloudflare (pull_request_target) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 12s
Guide screenshots / Guide images and local UI source review (pull_request) Failing after 19s
CI / Workflow lint (actionlint) (pull_request) Successful in 19s
Third-party parts / As their notes say (pull_request) Successful in 21s
PR description / Description follows the template (pull_request_target) Successful in 10s
This pull request is marked as a work in progress.
This branch is out-of-date with the base branch
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'feat/link-colours:mooki-feat/link-colours'
git switch 'mooki-feat/link-colours'
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/Longshot!1616
No description provided.