Psych Engine Logo
Psych Engine - Lua Script API

Substate Functions

Functions for Custom Substates, useful for in-game menus and mechanics.


openCustomSubstate

openCustomSubstate(name:String, ?pauseGame:Bool = false):Void

Opens an empty custom substate.

Examples:

Note: By default, the substate is completely blank when open, you can add Objects to it with "insertToCustomSubstate".


closeCustomSubstate

Usage: closeCustomSubstate()

Closes the custom substate.


insertToCustomSubstate

insertToCustomSubstate(tag:String, ?pos:Int = -1):Void

Inserts a Lua Sprite into the currently active Custom Substate.

Examples: