Skip to content

variants: robes' bone copies, cloaks' cloth by the torso, missing bones from the skeleton, cloaks for bodies with none - #106

Merged
plenarius merged 1 commit into
mainfrom
fix/variants-small-bodies
Oct 21, 2026
Merged

plenarius merged 1 commit into
mainfrom
fix/variants-small-bodies

Conversation

@plenarius

Copy link
Copy Markdown
Owner

Found while making Layonara's brownie robes and cloaks. Checked in game on brownies: generated robes and cloaks side by side with hand-made and human ones.

  • Robes' bone copies (pelvis_g, torso_g, ...) were moved to the target's joints but kept the source body's size. They are not drawn, but most cast the robe's shadow, and Bioware's race versions reshape them. They are now refitted like a skin vertex weighted wholly to their bone. A bone with no stock body part takes its nearest ancestor's width.
  • A cloak's cloth on its own bones (Cloak_g and below) kept the source body's size around them, so on a brownie the collar stood off the neck. It now takes the torso's width. This replaces widening the cloth by 0.4 of the chest's width ratio.
  • A bone the target's template robe lacks is taken from the target's skeleton. Example: Layonara's brownie robe 3 has no feet, and human robe 26 weights its hem to them, so the hem stayed human-wide and the robe-on-body preview put the feet below the ground. Feet now take the thighs' width, as shins do.
  • A body with no cloak at all no longer fails. The source cloak's bones are placed on its skeleton: under the neck, as wide as its chest, and the hanging chains as long as its neck-to-feet height. A warning says so. Such a body has to be named with --to.
  • A variant's supermodel names the skeleton its body uses (pmb0 for pmb2, which has no skeleton of its own) instead of a model that does not exist.

Mean distance per vertex from the hand-made or Bioware version:

before after
robes' bone copies, 56 hand-made brownie robes 10–11 cm 2.0–2.2 cm
robes' bone copies, Bioware's robes and cloaks of every race 4.85 cm 2.65 cm
Bioware's cloaks 1–7, phenotype 0 / 2 2.9 / 4.7 cm 1.8 / 4.0 cm
cloaks built from the skeleton (no template) fails 4.2 cm (2.7 with Bioware's template)
robe skins unchanged

Not fixed: a Large (phenotype 2) brownie's cloak still sits high around the head in game. It was accepted as is, since no one plays one.

Three new tests: TestVariantRefitsBoneCopies, TestVariantCloakFromSkeleton and TestVariantSuperModelIsTheBodysSkeleton. go test ./... passes. Variants code is not in the Python port.

…missing bones from the skeleton, cloaks for bodies with none

Found making Layonara's brownie robes and cloaks:

- A robe's bone copies (pelvis_g, torso_g, ...) were moved to the target's
  joints but kept the source body's size. They are not drawn, but most cast
  the robe's shadow, and Bioware's race versions reshape them. They are now
  refitted like a skin vertex weighted wholly to their bone; a bone with no
  stock body part takes its nearest ancestor's width. Against 56 hand-made
  brownie robes: 2.0 to 2.2 cm per vertex, from 10 to 11 cm; against
  Bioware's robes and cloaks of every race (154 pairs): 2.65 cm, from 4.85.
- A cloak's cloth on its own bones (Cloak_g and below) kept the source
  body's size around them: on a brownie the collar stood off the neck. It
  now takes the torso's width, which replaces widening the cloth by 0.4 of
  the chest's width ratio. Bioware's cloaks 1 to 7 of every race: 1.8 cm
  per vertex in phenotype 0 and 4.0 cm in phenotype 2, from 2.9 and 4.7.
- A bone the target's template robe lacks (Layonara's brownie robe 3 has no
  feet; human robe 26 weights its hem to them) is taken from the target's
  skeleton. Those vertices kept the human body's place, so the hem stayed
  human-wide, and the robe-on-body preview put the feet below the ground.
  Feet now take the thighs' width, as shins do.
- A body with no cloak at all no longer fails: the source cloak's bones are
  placed on the target's skeleton (under the neck, as wide as its chest,
  the hanging chains as long as its neck-to-feet height), with a warning
  saying so. Over Bioware's cloaks 1 to 7 of every race and phenotype, built
  this way: 4.2 cm per vertex from Bioware's, against 2.7 cm with Bioware's
  own cloak of that body as the template.
- A variant whose supermodel is its own body (pmb2_cloak_001 -> pmb2) now
  names the skeleton that body uses: a phenotype with no skeleton of its own
  uses phenotype 0's, so there was no pmb2 model to find. Stock bodies with
  their own skeleton (pmh2, pmd2) are unchanged.
@plenarius
plenarius merged commit e4ad0d5 into main Oct 21, 2026
9 checks passed
@plenarius plenarius mentioned this pull request Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant