/** * Adds a callback that's run when all assets are ready. * If all assets have already loaded, call the callback immediately. * * The first parameter of the callback function must be a function that * itself calls as a callback when it has finished. * * @param cb */ export function addCallback(cb: any): void; /** * Add an expected asset to the list. * * @param {function} asset */ export function expect(asset: Function): void; /** * As a bit of a hack this ensures the game starting callback is always * the last one. * * @param cb */ export function finalCallback(cb: any): void; /** * When an asset has finished loading, this method should be called. * * @param asset The name of the asset that's ready * @returns {boolean} true if asset was expected */ export function finished(asset: any): boolean;