planet-funk > "ts/sound" > Sound
Sound
● muffledVolume: number
Defined in ts/sound.ts:7
The volume to use for the sound when muffled is passed in.
● normalVolume: number
Defined in ts/sound.ts:11
The volume to use for the sound when conditions are normal.
● offset: number
Defined in ts/sound.ts:15
The offset that best suites the audio clip as many have dead space in the beginning.
● sound: Audio
Defined in ts/sound.ts:19
Audio clip belonging to this sound.
● wasPlaying: boolean
= false
Defined in ts/sound.ts:23
Flag to track if this sound had been paused.
▸ pause(): void
Defined in ts/sound.ts:51
Pauses clip if currently playing.
Returns: void
▸ play(muffled?: boolean
): void
Defined in ts/sound.ts:41
Activate the clip.
Parameters:
Param | Type |
---|---|
Optional muffled |
boolean |
Returns: void
▸ resume(): void
Defined in ts/sound.ts:60
Pauses clip if currently playing.
Returns: void
▸ stop(): void
Defined in ts/sound.ts:69
Stops the clip.
Returns: void