bird
<!-- zero:scaffolded-readme --> <!-- Replace the line below with what this module provides and who consumes it, then delete both comment lines. -->
bird
<!-- zero:scaffolded-readme --> <!-- Replace the line below with what this module provides and who consumes it, then delete both comment lines. -->TODO: describe this module.
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2strict
parts( ) → void
Every asset the bird is made of, resolved once per build. Each is spelled as a FULL identity, and each is a literal. Full, because the plume and the crest each name a mesh AND a material, and a bare leaf resolves to one of them with no regard for the type asked for. Literal, because a computed identity cannot be statically pinned, and content that cannot be pinned cannot be published.
blend(a: Pose, b: Pose, t: number) → Pose
Lerp two poses. `t` runs 0 (a) to 1 (b).
| arg | type | description |
|---|---|---|
| a | Pose | |
| b | Pose | |
| t | number |
l(x: number, y: number) → number return x
| arg | type | description |
|---|---|---|
| x | number | |
| y | number |
child(parent: any, name: string) → any
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string |
pivot(parent: any, name: string, pos: { number }) → any
A joint that turns: no scale, so nothing under it is sheared.
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string | |
| pos | { number } |
skin(parent: any, name: string, mesh: any, mat: any, scale: { number }?) → any
A mesh that is scaled: no rotation, so its own scale shears nothing.
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string | |
| mesh | any | |
| mat | any | |
| scale | { number }? |
build(parent: any, name: string) → Rig
Build one hernsew under `parent` and return its rig. Every entity is temporary: the roost rebuilds the whole flight on awake, so the scene never has to carry a hundred records it did not author.
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string |
apply(rig: Rig, p: Pose) → void
Posing. Write a pose onto a rig. Called every frame from the roost's update, so it resolves each joint by id rather than holding proxies across frames. The pose's neck angles are cumulative; the differences are what the joints are actually given.
| arg | type | description |
|---|---|---|
| rig | Rig | |
| p | Pose |
destroy(rig: Rig) → void
Tear one down. Despawning the root takes the whole chain with it.
| arg | type | description |
|---|---|---|
| rig | Rig |
Pose = {Rig = {Sub-parts
Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.
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.