API reference
Every public class, method, and event in @codexo/exojs. Generated from source.
interfaceSoundPlayOptions
@codexo/exojs / audio / stable
Per-call overrides for AudioSystem.play.
23
props
0
methods
0
events
Import
import { SoundPlayOptions } from '@codexo/exojs'Per-call overrides for AudioSystem.play.
Properties23
Route this play through a specific AudioBus.
coneInnerAngle?: numberInitial full-gain cone half-angle. Default 360 (no cone).
coneOuterAngle?: numberInitial falloff cone half-angle. Default 360.
coneOuterGain?: numberInitial gain outside the outer cone. Default 0.
detune?: numberOverride pitch detune (cents) for this play instance.
Initial distance-attenuation model. Default 'linear'.
elevation?: numberInitial height above the world plane. Default 0.
elevationVelocity?: numberInitial vertical velocity for Doppler. Default 0.
loop?: booleanOverride looping for this play instance.
maxDistance?: numberInitial max distance ('linear' model only). Default 1000.
muted?: booleanStart muted (volume 0).
occlusion?: numberInitial occlusion amount in [0, 1]. Default 0 (clear path).
orientation?: numberInitial cone facing direction, in degrees (SceneNode.rotation convention). Default 0.
panningModel?: PanningModelTypePer-play panning model override. Omit to inherit the app-wide default.
playbackRate?: numberOverride playback rate for this play instance.
position?: SpatialPointA point in the audio world: the 2D world plane, plus an optional out-of-plane height in the same units. `z` is optional everywhere it appears - a 2D game never… | VectorConcrete mutable 2D vector with full AbstractVector arithmetic and Collidable collision support (treated as a point collider). `Vector.temp` provides a shared…Initial spatial position - equivalent to setting voice.position right after play.
refDistance?: numberInitial reference distance. Default 50.
replace?: booleanWhen true, all currently-playing instances of this sound are stopped before the new one starts (singleton-replace mode). Useful for non-overlapping playback such as UI confirmation chimes. Default: false (multi-instance / pooled mode).
rolloffFactor?: numberInitial rolloff factor. Default 1.
sends?: readonly { bus: AudioBusHierarchical mixer node in the engine's audio routing graph. Each bus owns three Web Audio nodes (input gain, optional effect chain, stereo pan, output gain) a…; level?: number }[]Parallel sends to open on the voice right after play - one per bus.
time?: numberSeek offset in seconds before starting playback.
velocity?: SpatialPointA point in the audio world: the 2D world plane, plus an optional out-of-plane height in the same units. `z` is optional everywhere it appears - a 2D game never… | VectorConcrete mutable 2D vector with full AbstractVector arithmetic and Collidable collision support (treated as a point collider). `Vector.temp` provides a shared…Initial velocity for Doppler. See Spatializable.velocity.
volume?: numberOverride volume for this play instance. Range [0, 1].
Source