core
The plumbing every courseKit piece is built on: the course-wide look defaults (`setDefaults` with a theme or single families, `lookOf`), course frames (`frame`: author in metres along / to the side / up), `box` parts in a palette material with optional colliders, invisible `colli…
courseKit.core
The plumbing every courseKit piece is built on: the course-wide look defaults (setDefaults with a theme or single families, lookOf), course frames (frame: author in metres along / to the side / up), box parts in a palette material with optional colliders, invisible colliders, and the walkable footprints (record, recordRect, beginRun, run, footprint) that killUnder sizes a safety net from. Called by courseKit.parts, courseKit.pieces and re-exported by courseKit.api.
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2strict courseKit.core: the shared plumbing every course piece is built with: course-wide look defaults (one theme, or one look per family), course frames (author in metres along / to the side / up), box parts in a palette material with optional colliders, and the footprints walkable pieces record so a kill strip can size itself under them. Course pieces (courseKit.api, courseKit.pieces) are written on it; games call courseKit.api.
quat(deg: number) → void
A rotation quaternion `{x, y, z, w}` turning `deg` degrees about +Y.
| arg | type | description |
|---|---|---|
| deg | number |
pitch(rad: number) → void
A rotation quaternion `{x, y, z, w}` turning `rad` radians about +X (pitch).
| arg | type | description |
|---|---|---|
| rad | number |
mat(key: any) → any
The material for a palette key ("planks", "snow", "candyPink", ...); a material handle passes through.
| arg | type | description |
|---|---|---|
| key | any |
setDefaults(d: any) → any
Set course-wide defaults: { theme, deck, sign, lantern, water, reskin, platforms }. A `theme` sets every family from that theme first; the other keys then override single families.
| arg | type | description |
|---|---|---|
| d | any |
defaults( ) → any
The current course-wide defaults.
lookOf(family: string, o: any?) → any
The look record a piece uses: `o.look` when given, else the course-wide default of `family`.
| arg | type | description |
|---|---|---|
| family | string | |
| o | any? |
frame(origin: any, a: number, b: number?) → any
A course frame. origin = { x, y, z } (or x, z with y = 0), yaw in degrees. f.p(s, l, h) -> world point s metres along the yaw, l metres to its right, h above origin y.
| arg | type | description |
|---|---|---|
| origin | any | |
| a | number | |
| b | number? |
p(s: number, l: number, h: number) → void
| arg | type | description |
|---|---|---|
| s | number | |
| l | number | |
| h | number |
dir( ) → void
right( ) → void
box(parent: any, name: string, mat: any, pos: { number }, scale: { number }, opts: any?) → any
A box part under `parent` (local position / scale) in one material (palette key or handle). opts: mesh ("cube", "cylinder", "sphere", "cone", ...), euler {x, y, z} degrees, rotation (quaternion), collide, shadows.
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string | |
| mat | any | |
| pos | { number } | |
| scale | { number } | |
| opts | any? |
collider(parent: any, name: string, pos: { number }, scale: { number }, rotation: { number }?) → any
An invisible box collider under `parent` (local position / scale / rotation).
| arg | type | description |
|---|---|---|
| parent | any | |
| name | string | |
| pos | { number } | |
| scale | { number } | |
| rotation | { number }? |
record(e: any, cx: number, cz: number, ex: number, ez: number, top: number) → void
Record a walkable footprint (world x/z extents and the lowest walking height) for `e`.
| arg | type | description |
|---|---|---|
| e | any | |
| cx | number | |
| cz | number | |
| ex | number | |
| ez | number | |
| top | number |
recordRect(e: any, p: { number }, w: number, len: number, yaw: number, top: number) → void
Record a rectangle `w` across and `len` along `yaw`, centred at `p`, walked at height `top`.
| arg | type | description |
|---|---|---|
| e | any | |
| p | { number } | |
| w | number | |
| len | number | |
| yaw | number | |
| top | number |
beginRun( ) → void
Start a new run: kill strips made by `killUnder()` with no list cover what is placed after this.
run( ) → void
The footprints placed since `beginRun` ({ x0, x1, z0, z1, top, id } each).
footprint(e: any) → any
The footprint a course piece recorded (nil for entities the kit did not place).
| arg | type | description |
|---|---|---|
| e | any |
span(a: { number }, b: { number }) → void
Horizontal length, yaw (degrees) and rise from point `a` to point `b`.
| arg | type | description |
|---|---|---|
| a | { number } | |
| b | { number } |
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.