Viewer: Randomize button for a vehicle's parts #148

Manually merged
github merged 1 commit from gh-pr/148/head into gh-pr/148/base 2026-11-26 20:13:21 +00:00
Owner

@⁠holdmysocks on GitHub · 2026-11-24 13:06 UTC · original
holdmysocks:claude/parts-randomize → master · +77 −1 · 2 files · 1 commits · merged 2026-11-24 13:18 UTC

What

A Randomize button in the viewer's Parts panel for vehicles. It makes a random choice in every group of parts (bonnet, bumpers, exhaust, spoiler, skirts, roof, body and so on) from the options the loaded vehicle has.

  • A group that starts with a part always gets one of its options. A group that starts empty (an accessory) may also stay empty.
  • Only the vehicle's own options are used: the choice is made from the same list the panel's drop-downs show.
  • --random-parts <n> on the command line does one random choice after the load, with n as the seed, so a choice can be repeated and shown in a screenshot.

Checked

  • The elegy rendered with its default parts and with three seeds: three different sets of bonnet, bumpers, skirts, wing and roof rack, each a complete car.
  • Unit test for the choice rule (random_parts_keep_fitted_groups_fitted) passes.
  • The button itself was not clicked: it sits below the fold of the panel in a window screenshot. It calls the same function as --random-parts.

Not done

  • A random choice can combine parts that the game would not put together (the files' rules for which parts go with which are not decoded).
  • Colour and wheels are not randomized.
**@⁠holdmysocks** on GitHub · 2026-11-24 13:06 UTC · [original](https://github.com/holdmysocks/SixNG/pull/148) `holdmysocks:claude/parts-randomize` → `master` · +77 −1 · 2 files · 1 commits · merged 2026-11-24 13:18 UTC ## What A Randomize button in the viewer's Parts panel for vehicles. It makes a random choice in every group of parts (bonnet, bumpers, exhaust, spoiler, skirts, roof, body and so on) from the options the loaded vehicle has. - A group that starts with a part always gets one of its options. A group that starts empty (an accessory) may also stay empty. - Only the vehicle's own options are used: the choice is made from the same list the panel's drop-downs show. - `--random-parts <n>` on the command line does one random choice after the load, with `n` as the seed, so a choice can be repeated and shown in a screenshot. ## Checked - The elegy rendered with its default parts and with three seeds: three different sets of bonnet, bumpers, skirts, wing and roof rack, each a complete car. - Unit test for the choice rule (`random_parts_keep_fitted_groups_fitted`) passes. - The button itself was not clicked: it sits below the fold of the panel in a window screenshot. It calls the same function as `--random-parts`. ## Not done - A random choice can combine parts that the game would not put together (the files' rules for which parts go with which are not decoded). - Colour and wheels are not randomized.
A random choice in every group of parts from the options the loaded vehicle has; a group that starts with a part always gets one. --random-parts <seed> does the same once after the load.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 20:13:19 +00:00
github manually merged commit 796fa44218 into gh-pr/148/base 2026-11-26 20:13:21 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.