Skip to main content

SoundManagerOptions <Channel, SoundName>

Type parameters

  • Channel: string = string
  • SoundName: string = string

Index

Properties

optionalchannels

channels?: readonly (Channel | SoundChannelOptions<Channel>)[]

Optionally specify the possible channels to avoid typo's, as names or SoundChannelOptions

optionalmaxConcurrentTracks

maxConcurrentTracks?: number

Maximum number of simultaneously playing tracks allowed across ALL sounds managed by this SoundManager. Default is unbounded (Infinity). Channels can set their own cap with SoundChannelOptions.maxConcurrentTracks.

optionalonConnect

onConnect?: AudioBusBuilder

Wire the master input to output through effects (e.g. a compressor), see AudioBusBuilder

sounds

sounds: readonly (SoundConfig<NoInfer<Channel>, SoundName> | Sound<SoundName>)[]

The sounds to manage, each optionally with a mix volume and a channel.

optionalvoiceStealing

voiceStealing?: boolean

What happens when a maxConcurrentTracks cap *false (default) drops the new play *true stops the oldest playing track in that scope to make room for it.

optionalvolume

volume?: number

Master volume [0-1] for every sound in this manager

Default is 1 (100%)