Chamber.sceneModule
One paragraph describing what this module builds and where it belongs in a scene.
Chamber
One paragraph describing what this module builds and where it belongs in a scene.
Inputs
count: number(default 3) — what it controls, units, sensible range.spacing: number(default 1.5) — what it controls, units, sensible range.
Placement
local placed = entity.spawn("Chamber_0")
placed.component.add("SceneModule", {
source = asset.resolve("Chamber", "sceneModule"),
params = { count = 5 },
})
placed.localPosition = { 0, 0, 0 }
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2Chamber — the cave of EVERY Luminaria chamber, stacked down the mountain. OWNED BY THE CHAMBERS SLICE. One placement (scene entity "Cavern") builds every chamber in game.levels: chamber k's content sits under "chamber_<k>" at core.origin(k). After editing game/levels.module, rebuild: entity.find("Cavern").component.get("SceneModule"):rebuild() Per chamber it generates (deterministically, seeded by k) and lands as mesh assets inside this folder: * rock_shell an enclosed, tiered cavern: superelliptic walls that hug the play rectangle, two receding ledges, a noise-sculpted dome. Wound to face INWARD, so the orbit camera can swing behind a wall and still see in (the wall it is behind is culled). * floor a wet slate floor (flat where you walk) + box colliders and invisible walk bounds just outside the device grid. * rock_props boulders, stalagmites, columns and stalactites, ALL in the ring between the play rectangle and the wall (beams stop at the rectangle, so nothing here can sit in a beam's path), plus low pebbles inside that stay under beam height. * moss moss patches on the floor and moss-grown boulders. * crystals_<c> glowing amethyst / cyan / amber / rose clusters on ledges, walls and the floor ring, each colour one mesh; the biggest carry coloured point lights. * fissure a crystal crack in the ceiling above every emitter with a falling light shaft and a downward spot into the mist. * chamber 6 (theme "geode") a geode cathedral: higher dome, giant crystals ringing the walls and hanging from the ceiling. Device cells, the seal and the spawn are kept clear of everything solid. A "cave_keeper" entity runs CaveKeeper, which in play switches on only the chambers that can be seen, keeping the light count under the scene cap.
rng(seed: number) → void
small math
| arg | type | description |
|---|---|---|
| seed | number |
fbm(x: number, y: number, z: number, oct: number) → number
| arg | type | description |
|---|---|---|
| x | number | |
| y | number | |
| z | number | |
| oct | number |
smooth(e0: number, e1: number, x: number) → number
| arg | type | description |
|---|---|---|
| e0 | number | |
| e1 | number | |
| x | number |
norm3(x: number, y: number, z: number) → void
| arg | type | description |
|---|---|---|
| x | number | |
| y | number | |
| z | number |
cross(ax: ?, ay: ?, az: ?, bx: ?, by: ?, bz: ?) → void
| arg | type | description |
|---|---|---|
| ax | ? | |
| ay | ? | |
| az | ? | |
| bx | ? | |
| by | ? | |
| bz | ? |
hashStr(s: string) → string
| arg | type | description |
|---|---|---|
| s | string |
defKey(k: number, def: ?) → string
| arg | type | description |
|---|---|---|
| k | number | |
| def | ? |
G( ) → void
geometry accumulator (flat arrays, 0-based indices)
vert(g: ?, x: ?, y: ?, z: ?, nx: ?, ny: ?, nz: ?, u: ?, v: ?) → number
| arg | type | description |
|---|---|---|
| g | ? | |
| x | ? | |
| y | ? | |
| z | ? | |
| nx | ? | |
| ny | ? | |
| nz | ? | |
| u | ? | |
| v | ? |
tri(g: ?, a: ?, b: ?, c: ?) → void
| arg | type | description |
|---|---|---|
| g | ? | |
| a | ? | |
| b | ? | |
| c | ? |
out(g: ?) → void
| arg | type | description |
|---|---|---|
| g | ? |
smoothNormals(g: ?, v0: number, i0: number) → void
| arg | type | description |
|---|---|---|
| g | ? | |
| v0 | number | |
| i0 | number |
lattice(g: ?, rows: number, cols: number, fn: ?, inward: boolean) → void
A (rows+1) x (cols+1) lattice; column cols repeats column 0 (UV seam), and the seam normals are welded. Row i rises, column j turns counter-clockwise seen from above. outward = front faces point away from the axis.
| arg | type | description |
|---|---|---|
| g | ? | |
| rows | number | |
| cols | number | |
| fn | ? | |
| inward | boolean |
rot(yaw: number, tilt: number) → void
rotation R = Ry(yaw) * Rx(tilt), row-major 3x3
| arg | type | description |
|---|---|---|
| yaw | number | |
| tilt | number |
lathe(g: ?, profile: ?, sides: number, pos: ?, R: ?, sc: ?, disp: number, seed: number) → void
A lathed, noise-roughened solid: profile = { {r, y}, ... } ascending in y.
| arg | type | description |
|---|---|---|
| g | ? | |
| profile | ? | |
| sides | number | |
| pos | ? | |
| R | ? | |
| sc | ? | |
| disp | number | |
| seed | number |
face(g: ?, pts: ?, ref: ?) → void
Flat-shaded polygon (3 or 4 points) turned to face away from ref.
| arg | type | description |
|---|---|---|
| g | ? | |
| pts | ? | |
| ref | ? |
frame(ax: ?, ay: ?, az: ?) → void
An orthonormal frame (u, v) around the unit axis a.
| arg | type | description |
|---|---|---|
| ax | ? | |
| ay | ? | |
| az | ? |
shard(g: ?, rnd: ?, bx: ?, by: ?, bz: ?, ax: ?, ay: ?, az: ?, radius: ?, len: ?, tipLen: ?, twist: ?) → void
One quartz point: an irregular hexagonal prism (faces of unequal width, a slight taper and a waist ring that breaks the long faces) ending in a six-faced pyramidal termination whose apex sits a little off-axis, the way natural quartz grows. Flat-shaded, so every facet catches light on its own.
| arg | type | description |
|---|---|---|
| g | ? | |
| rnd | ? | |
| bx | ? | |
| by | ? | |
| bz | ? | |
| ax | ? | |
| ay | ? | |
| az | ? | |
| radius | ? | |
| len | ? | |
| tipLen | ? | |
| twist | ? |
ring(t: ?, r: ?) → void
| arg | type | description |
|---|---|---|
| t | ? | |
| r | ? |
axisPt(t: ?) → void
| arg | type | description |
|---|---|---|
| t | ? |
cluster(g: ?, rnd: ?, bx: ?, by: ?, bz: ?, ux: ?, uy: ?, uz: ?, size: number, count: number, spread: number?) → void
A tight radiating druse: a dominant point along the growth axis, the rest fanning out from a shared root, leaning further and growing shorter the further they stand from the centre, plus a skirt of small points at the foot. spread = the largest lean, in radians.
| arg | type | description |
|---|---|---|
| g | ? | |
| rnd | ? | |
| bx | ? | |
| by | ? | |
| bz | ? | |
| ux | ? | |
| uy | ? | |
| uz | ? | |
| size | number | |
| count | number | |
| spread | number? |
point(lean: ?, az: ?, L: ?, r: ?, off: ?) → void
| arg | type | description |
|---|---|---|
| lean | ? | |
| az | ? | |
| L | ? | |
| r | ? | |
| off | ? |
tex(name: string, set: string?) → string
materials (built into this folder) texture slots take a string ref (the texture's identity)
| arg | type | description |
|---|---|---|
| name | string | |
| set | string? |
shellAxes(def: ?) → void
| arg | type | description |
|---|---|---|
| def | ? |
ceilingAt(def: ?, H: ?, wallH: ?, x: ?, z: ?) → number
Height of the (un-noised) ceiling over chamber-local x, z.
| arg | type | description |
|---|---|---|
| def | ? | |
| H | ? | |
| wallH | ? | |
| x | ? | |
| z | ? |
shellGeom(def: ?, H: number, wallH: number, seed: number) → void
| arg | type | description |
|---|---|---|
| def | ? | |
| H | number | |
| wallH | number | |
| seed | number |
floorGeom(def: ?) → void
| arg | type | description |
|---|---|---|
| def | ? |
mossPatch(g: ?, rnd: ?, cx: number, cz: number, r: number, y0: number) → void
| arg | type | description |
|---|---|---|
| g | ? | |
| rnd | ? | |
| cx | number | |
| cz | number | |
| r | number | |
| y0 | number |
spawnModel(name: ?, parent: ?, mesh: ?, mat: ?, shadows: boolean?) → void
| arg | type | description |
|---|---|---|
| name | ? | |
| parent | ? | |
| mesh | ? | |
| mat | ? | |
| shadows | boolean? |
addLight(parent: ?, name: ?, x: ?, y: ?, z: ?, col: ?, intensity: ?, radius: ?) → void
| arg | type | description |
|---|---|---|
| parent | ? | |
| name | ? | |
| x | ? | |
| y | ? | |
| z | ? | |
| col | ? | |
| intensity | ? | |
| radius | ? |
buildChamber(k: number, def: ?) → void
| arg | type | description |
|---|---|---|
| k | number | |
| def | ? |
clear(x: number, z: number, rDev: number) → boolean
keep-clear tests
| arg | type | description |
|---|---|---|
| x | number | |
| z | number | |
| rDev | number |
ringPoint(o0: number, o1: number) → void
a point in the ring between the play rectangle and the wall
| arg | type | description |
|---|---|---|
| o0 | number | |
| o1 | number |
crystalG(name: ?) → void
| arg | type | description |
|---|---|---|
| name | ? |
pickColour( ) → void
addCluster(x: ?, y: ?, z: ?, ux: ?, uy: ?, uz: ?, size: ?, count: ?, colour: ?, lit: ?) → void
crystals: on the floor ring, on the ledges, out of the walls
| arg | type | description |
|---|---|---|
| x | ? | |
| y | ? | |
| z | ? | |
| ux | ? | |
| uy | ? | |
| uz | ? | |
| size | ? | |
| count | ? | |
| colour | ? | |
| lit | ? |
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 the 199 items nearest this part. It holds more than this page lists.
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.