Namespace: SceneManager

SceneManager

The static class that manages scene transitions.

Methods

SceneManager.backgroundBitmap()Bitmapstatic

Gets the background bitmap
Returns:
TypeDescription
BitmapThe background bitmap

SceneManager.catchException(e)static

Catching for exceptions
NameTypeDescription
eError|Array|*The error encountered

SceneManager.catchLoadError(e)static

Catching for load Errors
NameTypeDescription
eArrayArray of error information for the error encountered

SceneManager.catchNormalError(e)static

Catching for normal Error type errors
NameTypeDescription
eErrorThe error encountered

SceneManager.catchUnknownError(e)static

Catching for all other Errors
NameTypeDescription
e*An object of any type with error information

SceneManager.changeScene()static

Changes the scene, if needed

SceneManager.checkBrowser()static

Check if the player's browser supports necessary technologies to run an RPG Maker game
Throws:
Errors if browser does not support WebGL, Web Audio API, CSS Font Loading, or IndexedDB

SceneManager.checkPluginErrors()static

Check if any plugin errors exist

SceneManager.clearStack()static

Clears the scene stack

SceneManager.determineRepeatNumber(deltaTime)static

Check how many times to update based on time since last frame
NameTypeDescription
deltaTimenumberScalar time value from last frame to this frame.

SceneManager.exit()static

Exits the game

SceneManager.goto(sceneClass)static

Goes directly to the given scene
NameTypeDescription
sceneClassStageThe scene to go to

SceneManager.initAudio()static

Initializes WebAudio

SceneManager.initGraphics()static

Attempts to initialize Graphics
Throws:
Error if Graphics could not be initialized

SceneManager.initInput()static

Initializes Input and TouchInput

SceneManager.initVideo()static

Initializes Video

SceneManager.initialize()static

Initialize the SceneManager

SceneManager.isCurrentSceneBusy()booleanstatic

Check if the current scene is busy
Returns:
TypeDescription
booleanTrue if the scene is busy

SceneManager.isGameActive()booleanstatic

Check if the game window is active. Will also return true if this check could not be completed
Returns:
TypeDescription
booleanTrue if game window has focus.

SceneManager.isNextScene(sceneClass)booleanstatic

Check if the provided scene is the next scene
NameTypeDescription
sceneClassStageThe scene to check
Returns:
TypeDescription
booleanTrue if the passed scene class is the next scene

SceneManager.isPreviousScene(sceneClass)booleanstatic

Check if the provided scene is the previous scene
NameTypeDescription
sceneClassStageThe scene to check
Returns:
TypeDescription
booleanTrue if the passed scene class is the previous scene

SceneManager.isSceneChanging()booleanstatic

Check if the scene is changing
Returns:
TypeDescription
booleanTrue if game is exiting or there is a next scene to go to

SceneManager.onBeforeSceneStart()static

Handling before a scene is started

SceneManager.onError(event)static

Handling for errors
NameTypeDescription
eventObjectThe error event

SceneManager.onKeyDown(event)static

Handling for when a keydown event is fired. See Documentation
NameTypeDescription
eventeventThe keydown event

SceneManager.onReject(event)static

Handling for an uncaught exception in Promise when unhandledrejection event is fired. See Documentation
NameTypeDescription
eventObjectThe error event

SceneManager.onSceneCreate()static

Handling for when a scene is created

SceneManager.onSceneStart()static

Handling when a scene is started

SceneManager.onSceneTerminate()static

Handling for when a scene is terminated

SceneManager.onUnload()static

Handling for when an unload event is fired. See Documentation

SceneManager.pop()static

Pops the last scene on the end of the scene stack

SceneManager.prepareNextScene(arguments)static

Prepares the next scene with the given arguments
NameTypeDescription
arguments*Arguments to be passed to the next scene's prepare function

SceneManager.push(sceneClass)static

Pushes the given scene onto the end of the scene stack
NameTypeDescription
sceneClassStageThe scene to push to the stack

SceneManager.reloadGame()static

Reloads the game, if nwjs is available in the environment

SceneManager.resume()static

Resumes the main game loop

SceneManager.run(sceneClass)static

Starts the main game loop with the given scene class as the base stage
NameTypeDescription
sceneClassStageThe first scene when game starts, default is Scene_Boot

SceneManager.setupEventHandlers()static

Sets JS event listeners for error, unhandledrejection, unload, and keydown

SceneManager.showDevTools()static

Shows the chrome dev tools, if nwjs is available in the environment and is a test play

SceneManager.snap()Bitmapstatic

Snaps a bitmap of the current scene
Returns:
TypeDescription
BitmapA bitmap of the current scene as it appears when called

SceneManager.snapForBackground()static

Snaps a bitmap of the current scene for use in the background

SceneManager.stop()static

Stops the main game loop

SceneManager.terminate()static

Exit the game (if nwjs)

SceneManager.update(deltaTime)static

Updates the SceneManager
NameTypeDescription
deltaTimenumberScalar time value from last frame to this frame.

SceneManager.updateEffekseer()static

Update Effekseer

SceneManager.updateFrameCount()static

Add one to the frame count

SceneManager.updateInputData()static

Update Input and TouchInput

SceneManager.updateMain()static

Update the game

SceneManager.updateScene()static

Updates the current scene