Library: export a character as its outfit and body shape, in one GLB (#550) #552

Manually merged
github merged 1 commit from github-bot/gh-552 into gh-pr/552/base 2026-11-28 12:44:37 +00:00 AGit
Owner

@⁠holdmysocks on GitHub · 2026-11-28 12:27 UTC · original
holdmysocks:claude/people-library-outfit-export → master · +94 −1 · 3 files · 1 commits · merged 2026-11-28 12:38 UTC

Fixes #550. A user exported Raul from the library with an outfit and body mass picked, and got only a head, eyes, an earring and a shirt, and the shirt was the wrong one.

Cause

The library's Export button ran extract on the character's own default parts: the drawables named cs_raul_… in packs. It wrote one glTF per part. Three things were missing:

  • The outfit picked in the viewer. The Character panel shows outfits from the game's outfit list. Their clothes (trousers, shoes, a watch, the outfit's own shirt) are shared items, not cs_raul_… parts, so they were never in the export. The shirt was Raul's own default shirt, not the outfit's, and it had no tint.
  • The body shape. The panel's sliders never reached the job.
  • The viewer's own part choice. It was meant to follow the viewer, but the comparison failed once an outfit was picked, because the viewer's id then carries #look=<n>.

Fix

For a character, Export now queues sixng outfit <prefix> --archive <archive> --look <n> [--body-shape …] -o <out>/characters/<prefix>_outfit<n+1>.glb --tex both. That is one rigged GLB with the outfit's parts, tints and face.

  • Viewer shows the character: the export takes the outfit picked in the Character panel and the panel's full body shape (every control).
  • Viewer does not show it: the export takes outfit 1 (the viewer's default) in that outfit's own body-shape preset.
  • No outfit list for the character: the export takes its own default parts, as outfit does without --look.
  • The tooltip says which of these applies.
  • A job whose output is a .glb file now opens that file's folder from "Open output folder", instead of the file.

Other library items (drawables, animals) export as before.

Not covered

  • Parts hidden one by one in the viewer are not carried over. The export writes the whole outfit.
  • Strand hair is not written. That needs --hair, which the button does not pass.

Checks

  • Reproduced on master: the old job wrote six separate files for Raul: head, eyes, earring, the default shirt, and two small hair placeholders. There were no trousers or shoes, no tints and no body shape.
  • sixng outfit cs_raul --look 1 --body-shape gcweightbelly=0.8 writes one 26 MB GLB with the outfit's parts.
  • --look 0 into a folder that did not exist yet writes the GLB (25 MB, watch attached).
  • New test the_viewer_body_shape_reaches_the_export_whole: the panel's shape, written as the --body-shape text and parsed back by the CLI's parser, gives every control's value.
  • cargo test --release -p sixng-gui --bins passes.
**@⁠holdmysocks** on GitHub · 2026-11-28 12:27 UTC · [original](https://github.com/holdmysocks/SixNG/pull/552) `holdmysocks:claude/people-library-outfit-export` → `master` · +94 −1 · 3 files · 1 commits · merged 2026-11-28 12:38 UTC Fixes #550. A user exported Raul from the library with an outfit and body mass picked, and got only a head, eyes, an earring and a shirt, and the shirt was the wrong one. ## Cause The library's Export button ran `extract` on the character's own default parts: the drawables named `cs_raul_…` in packs. It wrote one glTF per part. Three things were missing: - **The outfit picked in the viewer.** The Character panel shows outfits from the game's outfit list. Their clothes (trousers, shoes, a watch, the outfit's own shirt) are shared items, not `cs_raul_…` parts, so they were never in the export. The shirt was Raul's own default shirt, not the outfit's, and it had no tint. - **The body shape.** The panel's sliders never reached the job. - **The viewer's own part choice.** It was meant to follow the viewer, but the comparison failed once an outfit was picked, because the viewer's id then carries `#look=<n>`. ## Fix For a character, Export now queues `sixng outfit <prefix> --archive <archive> --look <n> [--body-shape …] -o <out>/characters/<prefix>_outfit<n+1>.glb --tex both`. That is one rigged GLB with the outfit's parts, tints and face. - **Viewer shows the character:** the export takes the outfit picked in the Character panel and the panel's full body shape (every control). - **Viewer does not show it:** the export takes outfit 1 (the viewer's default) in that outfit's own body-shape preset. - **No outfit list for the character:** the export takes its own default parts, as `outfit` does without `--look`. - The tooltip says which of these applies. - A job whose output is a `.glb` file now opens that file's folder from "Open output folder", instead of the file. Other library items (drawables, animals) export as before. ## Not covered - Parts hidden one by one in the viewer are not carried over. The export writes the whole outfit. - Strand hair is not written. That needs `--hair`, which the button does not pass. ## Checks - Reproduced on master: the old job wrote six separate files for Raul: head, eyes, earring, the default shirt, and two small hair placeholders. There were no trousers or shoes, no tints and no body shape. - `sixng outfit cs_raul --look 1 --body-shape gcweightbelly=0.8` writes one 26 MB GLB with the outfit's parts. - `--look 0` into a folder that did not exist yet writes the GLB (25 MB, watch attached). - New test `the_viewer_body_shape_reaches_the_export_whole`: the panel's shape, written as the `--body-shape` text and parsed back by the CLI's parser, gives every control's value. - `cargo test --release -p sixng-gui --bins` passes.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 12:34:12 +00:00
github-bot changed target branch from master to gh-pr/552/base 2026-11-28 12:44:35 +00:00
github manually merged commit 4e31773de8 into gh-pr/552/base 2026-11-28 12:44:37 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.