ShadowUI 使用文档

Independent appearances — model schema 33

状态待核对Minecraft 1.21.10 · Forge / Bukkit
本页目录

本文对应 1.21.10 现代框架。文档中的接口与配置按当前文档快照核对;完整框架仍在开发验收。接口可编译、配置可解析与游戏内效果验证分别记录。

Decision: ADR-048(源码配套资料). Required capability: model_appearances_v33, in addition to model_bindings_v2.

An appearances row contains id, target: {kind: "player", uuid}, renderer: "aw", bodyResource, optional order (default 0), optional bodyVisible (default true), and slots. The initial body resource is an explicit namespaced models/*.glb. It declares a compatible skeleton; it does not bind or replace that player's body. A separate consumer can own the actual player model. Absent or incompatible bodies suspend appearance drawing.

At most 16 rows per owner and 12 AW slots per row are admitted. Each slot uses the existing rigid/segmented AW grammar: id, typed modelEntry, exact partIndex, upperBone, one of upperCalibration/upperRestAnchor, and optional offsetPixels/scale. Segmented slots additionally declare lowerBone, one lower matrix, optional lowerOffsetPixels, cutYPixels, and slimSide. Matrices are bounded invertible column-major affine frames; raw offsets/cuts are AW pixels. Slot IDs are unique. Unknown fields, missing joints, unsupported resources and failed geometry preparation reject the candidate. bodyVisible: false hides a compatible body only while the complete appearance is ready.

owner.bindAppearance(value), patchAppearance(id, patch), unbindAppearance(id) and appearance(id) use the same desired/applied revision and digest receipts as other model declarations. Patch fields are bodyResource, order, bodyVisible, and slots; each is a complete value. ID, target and renderer are immutable under patch. Configured actions are model:appearance_bind, model:appearance_patch and model:appearance_unbind; model:clear clears this profile's appearances too. Typed data expressions resolve before validation.

Appearance-only mutations preserve the body runtime and action clock. Owners have independent namespaces and resource leases. Additive rows render in ascending order, then stable row/owner ID order. Equal order does not imply exclusive ownership. Failed preparation retains the old applied appearance. Resources are prepared before publication; owner/session/revision/resource fences reject stale results. Owner retirement releases only its appearances, and body retirement does not delete another owner's declarations.

This contract initially exposes the existing GLB-body AW backend. Native biped/source-body and synthetic item-binding appearance adapters, V1 conversion and complete view coverage remain open requirements. Native automation, original-image review, migration, human acceptance and release are recorded separately in delivery-tasks.json.