StaticclearRemoves all scenes from the stack and resets the size and top-of-stack index.
StaticgetReturns the current number of scenes in the stack.
The stack size.
StaticpeekReturns the scene at the top of the stack without removing it.
The top ZScene, or null if the stack is empty.
StaticpopRemoves and returns the scene at the top of the stack.
The removed ZScene, or null if the stack is empty.
StaticpushPushes a scene onto the top of the stack.
The ZScene to push.
StaticresizeCalls resize(width, height) on every scene in the stack (top to bottom).
The new viewport width.
The new viewport height.
StaticspawnSearches the stack from top to bottom and calls spawn(templateName) on
each scene until one returns a container instance.
The template/asset name to spawn.
The spawned ZContainer, or undefined if not found in any scene.
Manages a stack of
ZSceneinstances, providing static methods to manipulate the stack.This class allows pushing, popping, peeking, and clearing scenes from the stack. It also provides utility methods to spawn entities from the topmost scene and resize all scenes in the stack.
Remarks