A task of pre-loading resources used by a scene.

A Promise can't be used instead of this class because a Promise will start as soon as possible. It would flood the server with downloading requests and make impossible to finely tune in which order scenes are actually downloaded.

Constructors

Properties

identifier: string
isFinished: boolean = false
onFinishCallbacks: (() => void)[]

Type declaration

    • (): void
    • Returns void

onProgressCallbacks: ((count, total) => void)[]

Type declaration

    • (count, total): void
    • Parameters

      • count: number
      • total: number

      Returns void

Methods

  • Parameters

    • onFinish: (() => void)
        • (): void
        • Returns void

    • Optional onProgress: ((count, total) => void)
        • (count, total): void
        • Parameters

          • count: number
          • total: number

          Returns void

    Returns void