sound_load()

Loads a sound file into a specified audio slot.

Syntax

sound_load(slot, filename)

Parameters

Parameter Type Description Comment
slot Number The index of the audio player slot (0 to 7). There are 8 slots available (0-7).
filename String The file path of the sound file to load.

Return Value

Examples

Load a sound file into the first audio slot (slot 0)

sound_load(0, "path/to/soundfile.wav"); 

Load a sound file into the second audio slot (slot 1)

sound_load(1, "path/to/anotherfile.wav"); 

See also

beep
siren
sound_load
sound_unload
sound_play
sound_stop
sound_is_playing