Sound.AudioPlayer

Description: Defines an AudioPlayer that is mapped to a specific source. Ultimately used to play the same sound simultaneously.

Constructors

AudioPlayer (source)
Creates a new instance of the AudioPlayer object.

source: string
Source path to an audio clip.

AudioPlayer (source)
Creates a new instance of the AudioPlayer object.

source: string[]
An array of source paths to audio clips. Pass in multiple audio types of the same clip to ensure cross browser compatibility.

Methods

BuildClip()
Builds an AudioClip with the default settings.

Play()
Builds an AudioClip and plays it with the default settings. Returns the built audio clip.

Examples

There's currently no example available for this page. If you'd like to suggest one send me an containing a description, code, and link to the page for the suggested example. As a thanks I'll associate the code snippet with your name directly below the example if approved.