Skip to content

API Interface OneShotOptions

github-actions[bot] edited this page Nov 30, 2026 · 5 revisions

Interface: OneShotOptions

Defined in: src/plugins/audio/runtime/oneShot.ts:21

Options for Audio.playOneShot (ADR 0074, api-and-models §1).

Properties

at?

at?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:37

Start at this audio-clock time (seconds, the base of Audio.time). Past or omitted: as soon as possible. Ignored while Audio.status is "locked". Non-finite: warns, plays now.


bus?

bus?: string;

Defined in: src/plugins/audio/runtime/oneShot.ts:33

The mixer bus to play on (ADR 0097); default Master. Unknown: Master plus the existing one-time warning.


dopplerLevel?

dopplerLevel?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:44

With a position: scales the Doppler shift from the listener's motion, 0..5. Default 0 (opt in).


highpass?

highpass?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:52

High-pass cutoff, Hz (10..24000; 20 and below is none).


lowpass?

lowpass?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:50

Low-pass cutoff, Hz (10..24000; 20000 and above is none). The lowest low-pass wins over automation's.


maxDistance?

maxDistance?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:31

With a position: the distance where the falloff stops, metres (default 100).


minDistance?

minDistance?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:29

With a position: full volume inside this distance, metres (default 1).


occlusion?

occlusion?: boolean;

Defined in: src/plugins/audio/runtime/oneShot.ts:42

With a position: walls between the sound and the listener muffle it. Default true.


offset?

offset?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:39

Start this many seconds into the clip (ADR 0343, 0348: audition from a point; a trimmed sample: into its trimmed sound, ADR 0342). 0 or omitted: the start; past the end it ends at once. Negative or non-finite: warns, plays from the start.


pitch?

pitch?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:27

Ratio, default 1, clamped 0.0625..16.


position?

position?: Vec3Like;

Defined in: src/plugins/audio/runtime/oneShot.ts:25

World metres; omitted = flat. Play spatially at this world point.


priority?

priority?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:35

0..255, default 128. Mostly decides who is stolen when a limit is hit; it only mildly raises audibility (at most +6 dB in selection).


reverbSend?

reverbSend?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:46

With a position: how much goes to the reverb zones that hold it, 0..2. Default 1.


reverbSendCurve?

reverbSendCurve?: Curve;

Defined in: src/plugins/audio/runtime/oneShot.ts:48

With a position: the reverb send against distance. Default: full send up close, half at maxDistance.


volume?

volume?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:23

Linear gain, default 1.


yaw?

yaw?: number;

Defined in: src/plugins/audio/runtime/oneShot.ts:54

Ambisonic clips: turns the recording about the vertical axis, degrees (-180..180), positive to the right (clockwise seen from above, ADR 0164).

Clone this wiki locally