- Called when the script is first created.
- Called at the end of "create".
- Called when the game updates.
- Called at the end of "update".
- Called when the global script is destroyed.
- Called when the game redraws.
- Called at the end of "draw".
- Called when the window loses focus.
- Called when the window gains focus.
- Called when the window is resized, with the parameters returning the new resolution.
- Called when the game first starts.
- Called when the game resets.
- Called at the end of "game reset".
- Called when you enter a new state/menu.
- Called at the end of "state switch".
- Called when the state is created. Returns the state that was created.
- Called when the Discord RPC presence is changed.
Note: onChangePresence was removed in version 0.2.0.