RhAudio
A module script.
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2Railhead: Dust Sea — procedural sound bank. Every cue in the game is synthesised here from first principles, encoded straight to the engine's ZAUD payload, and written as a `.soundClip` asset. Nothing is sampled or downloaded, so the whole sound design ships inside the world and stays editable as code. Baking writes to `/source`, which is locked while the world is playing, so `M.bake()` is an EDIT-mode operation. Gameplay only ever calls `M.play`.
rng(seed: number) → void
Deterministic noise so a re-bake produces byte-identical clips.
| arg | type | description |
|---|---|---|
| seed | number |
lp(a: number) → void
One-pole lowpass. `a` in (0,1]; smaller = darker.
| arg | type | description |
|---|---|---|
| a | number |
hp(a: number) → void
One-pole highpass built from its complementary lowpass.
| arg | type | description |
|---|---|---|
| a | number |
svf(f: number, q: number) → void
Resonant bandpass (state-variable). `f` Hz, `q` resonance.
| arg | type | description |
|---|---|---|
| f | number | |
| q | number |
softclip(x: number) → number
| arg | type | description |
|---|---|---|
| x | number |
decay(t: number, tau: number) → number
Exponential decay envelope.
| arg | type | description |
|---|---|---|
| t | number | |
| tau | number |
ad(t: number, atk: number, tau: number) → number
Attack/decay envelope.
| arg | type | description |
|---|---|---|
| t | number | |
| atk | number | |
| tau | number |
osc( ) → void
Sine that keeps its own phase so frequency can sweep without clicking.
sawOsc( ) → void
Bandlimited-ish saw from the same phase accumulator.
write(out: buffer, i: number, v: number) → void
| arg | type | description |
|---|---|---|
| out | buffer | |
| i | number | |
| v | number |
fire(out: ?, n: ?) → void
The shot. A hypervelocity rail discharge: an electrical crack that arrives first, the muzzle blast under it, and a sub-bass thump that carries.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
whine(out: ?, n: ?) → void
Capacitor whine while charging. Loops seamlessly; playback pitch rises with the charge level, so the pitch here is only the floor of the ramp.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
clunk(out: ?, n: ?) → void
The breech arming: a heavy metal clunk with a servo tail.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
sizzle(out: ?, n: ?) → void
Tracer sizzle — the ionised trail hissing as it recedes. Looped, with the doppler applied at playback via pitch.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
thud(out: ?, n: ?) → void
The impact, heard seconds after the flash. Mostly sub and rubble.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
shriek(out: ?, n: ?) → void
A machine dying: a resonant scream collapsing into scrap.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
beep(out: ?, n: ?) → void
Heat alarm: one short blip. Repeated by the game as the redline nears.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
klaxon(out: ?, n: ?) → void
Overheat klaxon: two-tone, harsh, unmistakable.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
vent(out: ?, n: ?) → void
Coolant purge: a pressurised hiss with a valve crack at the front.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
wind(out: ?, n: ?) → void
Canyon wind. Long loop, brown noise with a slow gust envelope.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
horn(out: ?, n: ?) → void
Wave horn: a huge low brass stack rolling across the canyon.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
drone(out: ?, n: ?) → void
The boss: a subsonic drone with slow beating partials.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
victory(out: ?, n: ?) → void
Victory: a wide open chord with a long tail.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
laze(out: ?, n: ?) → void
Rangefinder return.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
click(out: ?, n: ?) → void
UI click.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
hit(out: ?, n: ?) → void
Hit confirm: a clean bell so a connect reads over the noise.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
incoming(out: ?, n: ?) → void
An incoming mortar shell: descending whistle into the arrival.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
crack(out: ?, n: ?) → void
The battery taking a hit: armour crack plus scope glass.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
debris(out: ?, n: ?) → void
Rubble settling after an impact.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
ready(out: ?, n: ?) → void
Capacitor reaching full: a short rising two-tone.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
nearmiss(out: ?, n: ?) → void
The slug arriving at the battery's own position — a near miss overhead.
| arg | type | description |
|---|---|---|
| out | ? | |
| n | ? |
clipPath(name: string) → string
| arg | type | description |
|---|---|---|
| name | string |
clipIdentity(name: string) → string
| arg | type | description |
|---|---|---|
| name | string |
render(name: string) → void
Synthesise one cue and return its ZAUD payload.
| arg | type | description |
|---|---|---|
| name | string |
bake(force: boolean?) → void
Bake every cue to a `.soundClip` asset. EDIT MODE ONLY — `/source` is write-locked while the world plays, so a bake during play is shadowed and lost. Returns a per-cue report.
| arg | type | description |
|---|---|---|
| force | boolean? |
attach(parentId: string) → void
Attach the sound bank to `parentId`. Idempotent.
| arg | type | description |
|---|---|---|
| parentId | string |
play(name: string, opts: { volume: number?, pitch: number? }?) → void
Fire a one-shot. `opts` takes `volume` and `pitch`.
| arg | type | description |
|---|---|---|
| name | string | |
| opts | { volume: number?, pitch: number? }? |
loop(name: string, on: boolean, opts: { volume: number?, pitch: number? }?) → void
Start or stop a looping cue (whine, wind, drone, klaxon).
| arg | type | description |
|---|---|---|
| name | string | |
| on | boolean | |
| opts | { volume: number?, pitch: number? }? |
tune(name: string, volume: number, pitch: number) → void
Update a running loop's volume/pitch without restarting it.
| arg | type | description |
|---|---|---|
| name | string | |
| volume | number | |
| pitch | number |
detach( ) → void
Procedural sound bank: every cue in the game synthesised from oscillators, filters and envelopes, encoded straight to the engine's ZAUD payload and written as .soundClip assets. Includes the bake, an emitter rig and one-shot/loop playback.Sub-parts
Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.
Problems
Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.
Inside
1 problem across 1 itemagent_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.