Log inGet started
◇
component · drop-in viewer
asset⌬ componentcomponentprimary: init.luau·originates fromworld 3a9e3328-0…

Sound

<!-- zero:scaffolded-readme --> <!-- Replace the line below with what this component provides and who consumes it, then delete both comment lines. -->

by◐lauramarka·posted 1mo ago
What it does

Sound

<!-- zero:scaffolded-readme --> <!-- Replace the line below with what this component provides and who consumes it, then delete both comment lines. -->

TODO: describe this component.

Interface

What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.

conforms to

zero/source-extract/v2

game.sound.Sound — the village, heard. SOUND COMES FROM WHERE THE THING IS. Every bed here is an emitter ENTITY standing at the place it belongs to, so walking away from the tea stall fades it and walking to the pond brings the frogs up. Nothing is played from the player: the scene carries an `AudioListener` on the player's camera rig and the engine does the spatialisation, so this component only has to put the sources in the right places. Driven entirely by `game.Game.bus`: "place" → which bed leads "weather" → dry or rain "beat" → a story moment's one-shot THE ASSET PATHS ARE LITERALS, one per line, and that is not style. `asset. resolve` with a computed argument is REFUSED on a component or a scene entrypoint — the name cannot be pinned statically, so content using it cannot be published — so `DIR .. file` is an error and the full path is written out at each call site. It is also why the one-shots are a named table rather than a function taking a filename. The Bangla voice is NOT here yet: a line reaches this slice as text on `say` and there are no speech clips to play, so dialogue is silent until they are baked. Stated, not hidden.

Audio

grab(key: ?, ok: ?, ref: ?) → void

argtypedescription
key?
ok?
ref?

makeEmitter(key: ?, clip: ?, x: ?, y: ?, z: ?, volume: ?, radius: ?, looping: ?) → void

argtypedescription
key?
clip?
x?
y?
z?
volume?
radius?
looping?

setVolume(key: ?, value: ?) → void

argtypedescription
key?
value?

lead(key: string) → string

Bring one bed up and push the others back, so the mix follows the player through the village without anything stopping and starting.

argtypedescription
keystringThe bed to lead: birds, insects, wind, village, water or stall.

examples

sound:lead("water")

setRain(falling: boolean, heavy: boolean) → boolean

Turn the rain on and off. The rain beds are not wired yet: their clips did not resolve as `audio` assets, so this reports what it could not do rather than pretending the weather has a sound.

argtypedescription
fallingbooleanTrue to bring the rain in.
heavybooleanTrue for the monsoon downpour rather than light rain.

examples

sound:setRain(true, true)

shot(name: string) → boolean

Fire one of the named one-shots at the player.

argtypedescription
namestringOne of: door, step, fire, storm.

examples

sound:shot("door")

awake( ) → void

start( ) → void

Sub-parts

Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.

43items
·
soundclip · born here
❒asset
# SoundClip Managed audio asset. `data.zaud` is the engine-native ZAUD payload the runtime decodes and plays; compression settings live in `settings.yaml` (`clipRef:setSettings({ ... })` to change one).
▲ 0↑ born
·
soundclip · born here
❒asset
# SoundClip Managed audio asset. `data.zaud` is the engine-native ZAUD payload the runtime decodes and plays; compression settings live in `settings.yaml` (`clipRef:setSettings({ ... })` to change one).
▲ 0↑ born
·
soundclip · born here
❒asset
# SoundClip Managed audio asset. `data.zaud` is the engine-native ZAUD payload the runtime decodes and plays; compression settings live in `settings.yaml` (`clipRef:setSettings({ ... })` to change one).
▲ 0↑ born
·
soundclip · born here
❒asset
# SoundClip Managed audio asset. `data.zaud` is the engine-native ZAUD payload the runtime decodes and plays; compression settings live in `settings.yaml` (`clipRef:setSettings({ ... })` to change one).
▲ 0↑ born
·
soundclip · born here
❒asset
# SoundClip Managed audio asset. `data.zaud` is the engine-native ZAUD payload the runtime decodes and plays; compression settings live in `settings.yaml` (`clipRef:setSettings({ ... })` to change one).
▲ 0↑ born
▣
module · born here
❒asset
# game.Game The spine of **Hidden Love — A Bangladeshi Romance Story**. One shared module holding the constants and the rules, so no two slices have to agree by convention. ```lua local Game = require("game.Game") Game.bus.on("chapter", function(n) print(n) end) ``` Nothing here touches the engine at require time — it is data and pure functions, safe to require from a scene entrypoint, a component, a module or an `execute` chunk. ## What it holds | Field | What it is | |---|---| | `ART` | The art-direction sentence, verbatim from the reference pass. Every generated prompt reuses it word for word. | | `TITLE` / `SUBTITLE` / `ENDING_TITLE` | The title card and the closing card. | | `CAST` | The seven named people: who they are, what they wear, and the reference image for the two leads. | | `CHAPTERS` | The twelve chapters in order — `place`, `who`, `beat`, `objective`. The storyline is this table. | | `PLACES` | The seven sets the world slice builds, each with the reference image it answers to. | | `METERS` / `TIERS` | friendship, trust, closeness — and the three ways the same ending can land. | | `MOUNTS` | The names of the scene's mount entities a slice attaches to. | | `SLICES` | The five slice modules the entrypoint requires and mounts. | | `bus` | `on` / `off` / `emit`. How slices talk without requiring each other. | ## The rule the whole game runs on Every chapter reaches the end. The meters decide how *warm* the telling is, not whether it finishes — `warmth(state)` is the mean of the three meters as 0..1, and `tier(state)` names what that earns at the finale. ## State and saving `Game.newState()` is the whole save: chapter, the three meters, the choices taken, flags, the phone log, and time in chapter. `Game.SAVE_PATH` is where it is written, under `/zero/source/local/`. `Game.addMeter(state, key, amount)` clamps and announces on the bus; move the relationship through it and never by assignment, so everything watching stays in step. ## Mounting The scene lays down one entity per key in `Game.MOUNTS` and the entrypoint hands them to each slice's `mount(refs)`. A slice that is not present yet is not an error — the scene loads without it.
▲ 0↑ born
·
soundclip · born here
❒asset
# SoundClip Managed audio asset. `data.zaud` is the engine-native ZAUD payload the runtime decodes and plays; compression settings live in `settings.yaml` (`clipRef:setSettings({ ... })` to change one).
▲ 0↑ born
backing path · game/sound/Sound.component

Problems

Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.

0problems
No problems reported. This asset, its contents, and its direct deps are clean as of the latest commit.
⌬ZeroMind agent review · awaiting first pass
Findings
Reviewer findings (handle · model · tag · quoted note) appear here once the per-pass review log lands. Today only the rolled-up agent_score is exposed.
usability—
did it work as advertised
quality—
authoring polish + cohesion
performance—
frame & memory budget held
agent review score
—
/ 100
awaiting first pass
usability × 0.40
+ 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".

—%no reports yet
Sign in to report whether this part worked for you.
Discussion

Scoped to this part · feeds back into the world's score.

0comments
Sign in to post.sign in
No comments yet. Be the first.