Log inGet started
World

Nine Bells

Branchmain
Branchesmain
Commit5e921c28b2

README.md

The Bell — the sound of Ashcross

The score, the air of the quarantined district, the shared one-shot library every other slice calls, the mix, and every spoken line.

Nothing here is a recording. The whole bank is arithmetic — audio.synth renders it and audio.bake writes it out as .soundClip assets under /zero/source/audio. The bell is sixteen inharmonic partials struck twice a fraction of a hertz apart, in a reverb that grows from a street to a nave between the first toll and the ninth. The only recorded thing in the game is the speech, and that is re-voiced through the same kit.

What a slice calls

NB.sfx("vault")                        -- a one-shot
NB.sfx("step", { pitch = 1.05 })       -- with a trim
NB.sfx("brazier", { x = 12, y = 40 })  -- heard from where it happened
NB.music("late")                       -- crossfade the bed
NB.say("Bellman", "Nine. Ashcross is closed. God keep whoever is still inside it.")

An unknown name is a quiet no-op. NB.say always emits "say" first, so the field kit prints the line whether or not there is audio behind it.

The names

groupnames
feetstep (picks its own surface) · step_stone · step_wood · step_water
the arcjump · land · land_hard · ledge (grab) · drop · climb · bonk
the canevault · cane_probe (probe) · probe_sound · probe_rotten · board_crack · board_break (board.break)
the censerpuff (censer, smoke) · censer_chain · censer_empty (censer.empty) · brazier_refill (brazier, charcoal)
tincturestincture (drink) · tincture_theriac · tincture_aquavitae · tincture_vinegar · dash · belt · tincture.end · tincture.empty
the roundpickup · shutter · patient.near · treat_tick · treat_done (treat) · lantern_light (lantern) · gate · hurt · contagion_warn · won · lost
the infectedinfected_moan · infected_lunge · infected_ward (infected.recoil) · infected_calm (infected.calm) · cough
the field kitui_click (click) · ui_hover (hover) · ui_confirm (confirm) · ui_back (back) · ui_page (page)
the bellbell with opts.n = 1..9, or bell_1 … bell_9

NB.music(name): title · round · late · won (resolution) · lost · opening and none (silence). The bed turns from round to late on its own at the sixth bell.

The mix

Nothing sits at the same level as anything else. Loudest first: the bell, then the spoken line (which ducks the score to 42% while it lasts), then the doctor's body, then the score at 30%, then the air of the street at 20%, and the field kit quietest of all so it never argues with the district.

The air

amb_wind and amb_district run under the whole round. amb_rain fades in as the weather turns. amb_miasma swells around the doctor whenever NB.provide.inMiasmaAt says he is standing in it, and fades when he is not. amb_fire is spatial — a brazier is heard from where it stands, placed automatically the first time each one emits "brazier".

Voice

One read, four places. audio_gen.speech returns a single voice on this world (a documented male id, a documented female id and an impossible id all came back at the same 170.2 Hz median pitch, and none of them errored), so the characters are separated by what they say and by where they are standing when they say it: the Bellman is pitched down and thrown across the district into a stone tower, the Physician speaks from inside a beaked mask a hand's width from your ear, a Patient is heard through a shutter, the Warden under the arch of the lazaretto gate.

Every line the game is written to speak is already generated and cached as a .soundClip. A line nobody anticipated is generated the first time it is spoken and cached for the rest of the session — printed at once, spoken a moment later, and instant from then on.

NB.ext.audio

callwhat it does
setActive(on)sound runs in play mode; this forces it either way
setFootSurface(name)"stone" / "wood" / "water" / "auto"
setWeather(kind, 0..1)"rain" / "wind" / "district"
placeLoop(kind, x, y, opts)a spatial looping emitter — "fire" / "miasma" / "rain"
prewarm({ { who, text } })generate lines before they are needed
duck(seconds, amount)push the score down for a moment
mixthe live gain table

Rebuilding the bank

local B = require("audio.bake")
B.bakeSfx()        -- every one-shot
B.bakeBells(1, 9)  -- the nine tolls
B.bakeMusic()      -- the beds
B.bakeAmbience()   -- the air
B.bakeVoice()      -- the canonical script

Run it from an execute, never from a component or a scene entrypoint: an asset.create made from either writes to the runtime store instead of /zero/source, and the clip would not survive a reload. The noise is a seeded LCG, so a re-bake is byte-identical.