跳转到内容

SceneManagerState

此内容尚不支持你的语言。

Defined in: scene/sceneManager.ts:283

Scene loading and transitions, as Res(SceneManager) hands it over. A scene is a unit of ownership as much as of content: what it spawned is despawned and what it acquired is released when it unloads.

@beta: the vocabulary is settled, but one certified project drives it against twenty-six signatures — thin evidence for that breadth of promise.

new SceneManagerState(app): SceneManagerState

Defined in: scene/sceneManager.ts:299

App

SceneManagerState

bringToTop(name): void

Defined in: scene/sceneManager.ts:982

string

void


discardPrepared(name): number

Defined in: scene/sceneManager.ts:468

Give back what prepare readied, answering how many acquisitions came back with it. Zero for a scene that readied nothing.

string

number


getActive(): string | null

Defined in: scene/sceneManager.ts:960

string | null


getActiveScenes(): string[]

Defined in: scene/sceneManager.ts:964

string[]


getInitial(): string | null

Defined in: scene/sceneManager.ts:356

string | null


getLoaded(): string[]

Defined in: scene/sceneManager.ts:974

string[]


getLoadOrder(): string[]

Defined in: scene/sceneManager.ts:978

string[]


getScene(name): SceneContext | null

Defined in: scene/sceneManager.ts:989

string

SceneContext | null


getSceneStatus(name): SceneStatus | null

Defined in: scene/sceneManager.ts:993

string

SceneStatus | null


isActive(name): boolean

Defined in: scene/sceneManager.ts:956

string

boolean


isLoaded(name): boolean

Defined in: scene/sceneManager.ts:952

string

boolean


isPaused(name): boolean

Defined in: scene/sceneManager.ts:944

string

boolean


isSleeping(name): boolean

Defined in: scene/sceneManager.ts:948

string

boolean


isTransitioning(): boolean

Defined in: scene/sceneManager.ts:360

boolean


load(name, onProgress?): Promise<SceneContext>

Defined in: scene/sceneManager.ts:435

Replace whatever is active with name.

string

SceneLoadProgressCallback

Promise<SceneContext>


loadAdditive(name, onProgress?): Promise<SceneContext>

Defined in: scene/sceneManager.ts:440

Bring name up alongside whatever is already running.

string

SceneLoadProgressCallback

Promise<SceneContext>


pause(name): void

Defined in: scene/sceneManager.ts:860

string

void


prepare(name): Promise<void>

Defined in: scene/sceneManager.ts:448

Ready name without bringing it up. A no-op for a scene that declares no preparation, and for one already loaded — there is nothing left to hide.

string

Promise<void>


readyRenderPrograms(name): Promise<RenderReadiness>

Defined in: scene/sceneManager.ts:458

Make the render programs name’s prepared content requires ready.

string

Promise<RenderReadiness>

Not applicable where the scene declares no readying or is already up; otherwise the claim, or null when one could not be made.


register(config): void

Defined in: scene/sceneManager.ts:348

SceneConfig

void


reload(options?): Promise<void>

Defined in: scene/sceneManager.ts:374

Start the active scene over: retire it and bring it back up, entities and all. switchTo cannot express this — asked for the scene already running it does nothing, which is the right answer for a gate and the wrong one for every death, retry and restart there is.

TransitionOptions

Promise<void>


reset(): void

Defined in: scene/sceneManager.ts:320

Forget the scenes while the caller keeps the World.

scene-teardown: NOT the shared protocol. Entities stay, so what they still render must not be released under them — and a dropped instance therefore keeps its receipts and systems. No caller in this repo says if that is right.

void


resume(name): void

Defined in: scene/sceneManager.ts:868

string

void


setInitial(name): void

Defined in: scene/sceneManager.ts:352

string

void


sleep(name): void

Defined in: scene/sceneManager.ts:876

string

void


switchTo(name, options?): Promise<void>

Defined in: scene/sceneManager.ts:364

string

TransitionOptions

Promise<void>


unload(name, options?): Promise<void>

Defined in: scene/sceneManager.ts:725

string

TransitionOptions

Promise<void>


updateTransition(dt): void

Defined in: scene/sceneManager.ts:430

number

void


wake(name): void

Defined in: scene/sceneManager.ts:910

string

void