sidebarCharacter Creator Demo UI

This page documents CharacterCreatorDemoUI in detail.

It explains:

  • What the component does.

  • Which references are required.

  • What each Inspector group means.

  • How to bind a spawned character at runtime.

  • How tabs, colors, blendshapes, and presets behave.

Purpose

CharacterCreatorDemoUI is a runtime UI orchestrator for Character Creator.

It builds and controls:

  • Equipment rows (with optional color + slot filtering).

  • Optional Head tab (Hair/Face equipment).

  • Optional Expressions tab.

  • Body tab controls (body part length, uniform scale, skin/eye color controls, body blendshapes).

  • Preset save/load/delete list with portraits.

The component clones disabled templates at runtime and refreshes everything through RebuildUI().

Requirements

Core runtime dependencies:

  • EquipmentManager

  • CharacterPresetManager

  • BlendshapeSynchronizer

  • SkinnedMeshRenderer body renderer with blendshapes

Optional dependencies:

  • BodyPartLengthAdjuster for arm/leg/neck/torso sliders.

  • SkinnedMeshRenderer expression renderer for expression blendshapes.

Inspector Reference

Core References

Field
Required
Notes

Equipment Manager

Yes

Source of registered equipment, equip/unequip actions, thumbnails.

Blendshape Synchronizer

Recommended

Used for SyncNow() after body blendshape changes.

Preset Manager

Yes

Used for save/load/delete presets, portraits, and material tracking metadata.

Body Renderer

Yes

Main body blendshape source. If null, UI tries to use BlendshapeSynchronizer.SourceRenderer.

Expression Renderer

Optional

Used for the Expressions tab. Auto-resolved if possible.

Body Part Adjuster

Optional

Enables body part length sliders.

UI Panels

Field
Required
Notes

Equipment Panel

Yes

Equipment tab content root.

Head Panel

Optional

Required only if Head tab is enabled.

Blendshape Panel

No

Kept for compatibility; hidden by runtime flow.

Expression Panel

Optional

Required only if Expressions tab is enabled.

Body Scale Panel

Yes

Contains body sliders and body color controls.

Preset Panel

Yes

Preset save/load/delete content.

UI Templates (disabled in scene)

Field
Required
Notes

Equip Button Template

Yes

Row button template for Equipment tab entries.

Head Equip Button Template

Optional

Used when Head tab is enabled.

Blendshape Slider Template

Yes

Template for body blendshape rows.

Expression Slider Template

Optional

Template for expression blendshape rows.

Preset Entry Template

Yes

Template for each preset entry in the list.

Preset UI

Field
Required
Notes

Preset Name Input

Recommended

Empty falls back to "Preset".

Save Preset Button

Yes

Triggers SavePreset.

Preset List Content

Yes

Parent for runtime-cloned preset entries.

Body Scale Sliders

Field
Required
Notes

Arms Slider

Optional

Disabled automatically if no BodyPartLengthAdjuster.

Legs Slider

Optional

Same behavior as above.

Neck Slider

Optional

Same behavior as above.

Torso Slider

Optional

Same behavior as above.

Uniform Scale Slider

Optional

Controls character root scale (via EquipmentManager root when available).

Tab Buttons

Field
Required
Notes

Tab Equipment

Yes

Shows equipment panel.

Tab Head

Optional

Activated only when Head tab is valid at runtime.

Tab Blendshapes

No

Disabled by code; kept for compatibility.

Tab Expressions

Optional

Activated only when Expressions tab is valid at runtime.

Tab Body Scale

Yes

Shows body panel.

Tab Presets

Yes

Shows presets panel.

Debug

Field
Notes

Debug Blendshape Sync

Logs startup diagnostics, slider changes, and external override re-application behavior.

Feature Toggles

Field
Behavior

Enable Equipment Per Slot Color Override

Shows a Slots button per equipped item to choose editable sub-material slots.

Enable Head Tab For Hair And Face

Moves Hair/Face equipment into a separate Head tab when valid.

Enable Expression Tab

Enables Expressions tab if an expression renderer with blendshapes is available.

Enforce Touched Blendshape Values

Re-applies touched slider values in LateUpdate to fight animation overrides.

Blendshape Filters (optional)

Field
Behavior

Blendshape Filter Profile

Direct profile for show/hide and display-name override per blendshape.

Blendshape Filter Catalog

Profile catalog for runtime auto-resolution by character/mesh match.

Auto Resolve Blendshape Filter From Catalog

If direct profile is null, resolve from catalog automatically.

Optional Default Head Meshes

Field
Behavior

Default Hair Object

Disabled while any Hair slot equipment is equipped, re-enabled otherwise.

Default Face Object

Disabled while any Face slot equipment is equipped, re-enabled otherwise.

Public Runtime API

BindCharacter(GameObject characterRoot)

Auto-discovers:

  • EquipmentManager

  • BlendshapeSynchronizer

  • CharacterPresetManager

  • BodyPartLengthAdjuster

  • best body SkinnedMeshRenderer

Returns false if required references are missing after discovery.

BindCharacter(GameObject characterRoot, bool rebuildUI)

Same as above with explicit rebuild control.

BindCharacter(EquipmentManager, BlendshapeSynchronizer, CharacterPresetManager, SkinnedMeshRenderer, BodyPartLengthAdjuster)

Explicit bind overload. Equivalent to the 6-arg overload with rebuildUI = true.

BindCharacter(..., bool rebuildUI)

Fully explicit bind with optional rebuild.

RebuildUI()

Full runtime rebuild flow:

  1. Clears old generated rows/popups/portrait textures.

  2. Resolves body/expression renderer references.

  3. Resolves blendshape filter profile.

  4. Builds equipment/head rows.

  5. Rewires tabs.

  6. Builds body panel controls and blendshape rows.

  7. Builds expression rows.

  8. Rebuilds preset list.

  9. Shows default panel.

Runtime Behavior Notes

Equipment rows

Each row provides:

  • Equip/Unequip button.

  • Thumbnail.

  • Color preview + Color button.

  • Optional Slots button (per-sub-material selection mode).

Head slot behavior:

  • Equipping Hair/Face in Head context auto-detaches existing item in the same slot first.

Thumbnail previews

  • Hover preview popup appears on pointer enter.

  • Click thumbnail toggles a larger pinned preview popup.

  • Close button is provided on pinned preview popup.

Body blendshapes and expressions

  • Body blendshapes are created in the body panel section (Body Blendshapes).

  • Expressions tab uses the expression renderer.

  • If expression tab is enabled, body blendshape list excludes detected expression-like shapes.

  • Filter profile can explicitly control visibility and display labels.

Color controls

Body panel color UI provides:

  • Skin palette + custom picker.

  • Eye palette + custom picker.

  • Runtime HSV wheel + SV square popup.

Material target discovery order:

  1. CharacterPresetManager explicit skin/eye slots.

  2. Tracked renderers + known color properties.

  3. Body-renderer fallback target if needed.

Face sync rule:

  • Applying skin color also pushes that skin tone to currently equipped Face-slot equipment.

  • Equipping a Face item triggers body-skin-to-face sync immediately.

Presets panel

Supports:

  • Save preset.

  • Load preset.

  • Delete preset.

  • Portrait thumbnail display.

On load:

  • Applies preset through CharacterPresetManager.

  • Syncs slider UI values.

  • Refreshes equipment button states.

  • Re-evaluates default hair/face visibility.

Template Contract

Slider templates

Both body and expression slider templates should include:

  • Slider

  • Text label

Preset entry template

Expected child names:

  • PresetName (Text)

  • Portrait (RawImage)

  • LoadButton (Button)

  • DeleteButton (Button)

Equipment row templates

The row template should contain:

  • main Button

  • label Text

Color preview, Slots button, and thumbnail are generated by script.

Typical Usage (Runtime Spawn)

  1. Spawn character prefab.

  2. Call BindCharacter(spawnedRoot, true).

  3. Let player customize.

  4. Use preset save/load flows normally.

  5. Rebind after character swap/respawn.

Troubleshooting

Symptom
Likely cause
Fix

Head tab not visible

Toggle off, missing head panel/template, or no Hair/Face entries

Enable toggle, assign panel/template, ensure EquipmentManager has Hair/Face prefabs

Expressions tab not visible

Missing expression renderer/template or no blendshapes

Assign Expression Renderer or Default Face Object, ensure template exists

Blendshape sliders fight animation

Animator clip writes blendshapes

Keep Enforce Touched Blendshape Values enabled or remove conflicting animation curves

Equipment color button disabled

Item not equipped

Equip item first

Slots popup has no rows

No supported color property found on equipped materials

Add/verify color property names via CharacterPresetManager.EquipmentColorPropertyNames

Preset list portrait missing

No portrait saved for that preset

Save preset again with portrait capture enabled in CharacterPresetManager

Wrong character controlled after respawn

UI still bound to old instance

Rebind with BindCharacter(newRoot, true)

Last updated