skel
The man's skeleton as three.js holds it: local and world bone transforms, clip mixing the way three.js's AnimationMixer blends (bind pose for the weight left over), world-space bone turns, and the pose for the engine's skinning sinks. Used by the animator.
skel
The man's skeleton as three.js holds it: local and world bone transforms, clip mixing the way three.js's AnimationMixer blends (bind pose for the weight left over), world-space bone turns, and the pose for the engine's skinning sinks. Used by the animator.
Ported from blendi/painted-valley on Patch (MIT).
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2strict
subtrees(man: Man) → void
each bone's own subtree (itself first, then its descendants, parents before children)
| arg | type | description |
|---|---|---|
| man | Man |
new(man: Man) → Skel
| arg | type | description |
|---|---|---|
| man | Man |
allDirty(self: Skel) → void
| arg | type | description |
|---|---|---|
| self | Skel |
markDirty(self: Skel, i: number) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number |
setObject(self: Skel, pos: vector, qx: number, qy: number, qz: number, qw: number) → void
Places the man (his object: the glTF scene root) in the world.
| arg | type | description |
|---|---|---|
| self | Skel | |
| pos | vector | |
| qx | number | |
| qy | number | |
| qz | number | |
| qw | number |
ensure(self: Skel, i: number) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number |
worldPos(self: Skel, i: number) → vector
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number |
worldQuat(self: Skel, i: number) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number |
parentWorldQuat(self: Skel, i: number) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number |
localQuat(self: Skel, i: number) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number |
setLocalQuat(self: Skel, i: number, x: number, y: number, z: number, w: number) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number | |
| x | number | |
| y | number | |
| z | number | |
| w | number |
setLocalPos(self: Skel, i: number, v: vector) → void
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number | |
| v | vector |
rotateWorldQ(self: Skel, i: number, qx: number, qy: number, qz: number, qw: number) → void
The bone turned by q in world space (the original's rotateWorldQ).
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number | |
| qx | number | |
| qy | number | |
| qz | number | |
| qw | number |
rotateWorld(self: Skel, i: number, axis: vector, angle: number) → void
The bone turned by `angle` about a world axis (the original's rotateWorld).
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number | |
| axis | vector | |
| angle | number |
parentLocal(self: Skel, i: number, pw: vector) → vector
A world point in the frame of bone i's parent (Object3D.worldToLocal on the parent).
| arg | type | description |
|---|---|---|
| self | Skel | |
| i | number | |
| pw | vector |
toObject(self: Skel, v: vector) → vector
A world point in the man's own frame (applyMatrix4 of his inverse world matrix).
| arg | type | description |
|---|---|---|
| self | Skel | |
| v | vector |
objectDir(self: Skel, v: vector) → vector
A direction in the man's frame turned into the world (e.g. (0, 0, 1) is his forward).
| arg | type | description |
|---|---|---|
| self | Skel | |
| v | vector |
sampleQ(tr: Track, t: number) → void
| arg | type | description |
|---|---|---|
| tr | Track | |
| t | number |
sampleV(tr: Track, t: number) → vector
| arg | type | description |
|---|---|---|
| tr | Track | |
| t | number |
byOrder(a: Sample, b: Sample) → boolean
| arg | type | description |
|---|---|---|
| a | Sample | |
| b | Sample |
mix(self: Skel, samples: { Sample }) → void
Poses the skeleton from weighted clip samples as three.js's mixer does (mixer.update after setting each action's weight and time): per property, the actions with a track for it blended in their order, the weight they leave over taken from the bind pose. In-place samples leave root's tracks out.
| arg | type | description |
|---|---|---|
| self | Skel | |
| samples | { Sample } |
toBind(self: Skel) → void
| arg | type | description |
|---|---|---|
| self | Skel |
poseValues(self: Skel) → void
The local pose as the engine's pose sink takes it: stride 10 (translation, rotation x y z w, scale).
| arg | type | description |
|---|---|---|
| self | Skel |
Sample = { clip: Clip, w: number, time: number, inPlace: boolean, slot: number }Skel = typeof(setmetatable({} :: SkelData, Skel))The man's skeleton as three.js holds itSub-parts
Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.
Showing up to 3 levels deep. Open a part to see what it holds further down.
Problems
Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.
agent_score is exposed.+ quality × 0.35
+ performance × 0.25
± compat factor
Usability ratings
Did the part work as advertised when consumers tried to drop it in. Separate from upvotes: those are taste; this is "did it function".
Scoped to this part · feeds back into the world's score.