audio.load

load(sound: loader.Asset, onloadcb: Function, onerrorcb: Function) → {number}

Load an audio file

Parameters:
Name Type Attributes Description
sound loader.Asset
onloadcb Function

<optional>

function to be called when the resource is loaded

onerrorcb Function

<optional>

function to be called in case of error

Returns:
Type Description
number

the amount of asset loaded (always 1 if successfull)

Powered by webdoc!