toddler
<!-- zero:scaffolded-readme --> <!-- Replace the line below with what this module provides and who consumes it, then delete both comment lines. -->
toddler
<!-- 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/v2characters/toddler.module — OWNED BY THE CHARACTERS SLICE. Builds the toddler soldier visual (red / blue team) and the first-person viewmodel (chubby red-sleeved hand holding the stick rifle), and plays the toddler's poses. Consumed by the GAMEPLAY slice (game/*). The toddler is a sculpted claymation figure: chubby clay primitives wearing generated clay / knit / crayon-camo materials (characters/materials/*), arranged on a pivot rig (pv_body, pv_head, pv_armL/R, pv_legL/R, pv_stars) that the ToddlerRig component animates procedurally. Conventions * The visual's origin is at the FEET (y = 0); it is 0.95 m tall. * It FACES the engine's forward, -Z. Yaw the parent so its `transform.forward` points where the toddler walks / aims. * Gameplay owns movement / physics / colliders on the parent. API spawnToddler(team, parent) -> visual root ("toddler_visual") setPose(visual, pose[, rate]) idle | run | throw | stunned | timeout spawnViewmodel(cameraEntity) -> viewmodel root (child of the camera) muzzlePosition(viewmodel) -> {x,y,z} world tip of the stick rifle dressPlayer(player[, team]) hides the humanoid avatar body of the ToddlerPlayer and puts a toddler visual on it (head/arms hidden so the first-person eye is not inside them)
mat(name: string) → any
| arg | type | description |
|---|---|---|
| name | string |
pivot(parent: any, name: string, pos: { number }) → any
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string | |
| pos | { number } |
teamMats(team: string) → void
| arg | type | description |
|---|---|---|
| team | string |
buildLeg(body: any, side: number, tm: any) → void
| arg | type | description |
|---|---|---|
| body | any | |
| side | number | |
| tm | any |
buildArm(body: any, side: number, tm: any) → void
| arg | type | description |
|---|---|---|
| body | any | |
| side | number | |
| tm | any |
buildHead(body: any, tm: any) → any
| arg | type | description |
|---|---|---|
| body | any | |
| tm | any |
spawnToddler(team: string, parent: any) → any
Spawn a toddler soldier's visual hierarchy under `parent`, coloured for `team` ("red"|"blue"). Returns the visual root entity (origin at the feet, facing -Z). Gameplay owns movement/physics on the parent.
| arg | type | description |
|---|---|---|
| team | string | |
| parent | any |
setPose(visual: any, pose: string, rate: number?) → void
Play a named pose on a toddler visual: "idle"|"run"|"throw"|"stunned"|"timeout". `rate` (optional) scales the cycle speed, e.g. run speed / walkSpeed. "throw" is one-shot (0.8 s) and settles back to standing; call setPose again to re-throw.
| arg | type | description |
|---|---|---|
| visual | any | |
| pose | string | |
| rate | number? |
buildStickRifle(gun: any) → void
| arg | type | description |
|---|---|---|
| gun | any |
buildHand(gun: any) → void
| arg | type | description |
|---|---|---|
| gun | any |
at(d: number) → void
| arg | type | description |
|---|---|---|
| d | number |
spawnViewmodel(cameraEntity: any) → any
Spawn the first-person viewmodel (chubby red-sleeved hand holding the stick rifle) under `cameraEntity`, in the lower right of the view. Replaces an existing one. Returns its root; a ViewmodelRig on it bobs with movement and kicks on Rules "fire".
| arg | type | description |
|---|---|---|
| cameraEntity | any |
muzzlePosition(viewmodel: any) → void
World position {x,y,z} of the stick rifle's muzzle on a viewmodel (for the crayon PEW! burst), or nil.
| arg | type | description |
|---|---|---|
| viewmodel | any |
find(e: any) → any
| arg | type | description |
|---|---|---|
| e | any |
hideModels(e: any) → void
| arg | type | description |
|---|---|---|
| e | any |
dressPlayer(player: any, team: string?) → any
Give the ToddlerPlayer instance a toddler look: hides the humanoid avatar under its "body" child (retrying while it hydrates) and spawns a toddler visual (team colour, default red) on the player root with head and arms hidden, so the first-person camera at 0.75 m sits in clear air and looking down shows the shirt, diaper, legs and sneakers. Returns the visual.
| arg | type | description |
|---|---|---|
| player | any | |
| team | string? |
shrink(e: any) → void
| arg | type | description |
|---|---|---|
| e | any |
Sub-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.