Skip to content
Eloy Villasclaras edited this page Apr 18, 2016 · 1 revision

<state> adds a Phaser.State to the game. One or several state nodes can be definedl they must be children of the <game> node.

Similarly to <game> nodes, <state> adds a Phaser.State object; the preload, create and update methods are implemented automatically. The following children nodes of a <state> are initialized during the create method:

Properties

These properties are set when the component is first mounted, and updated in later renders, if their value changes.

Property Notes
name Unique identifier of the node. <game> property stateName can be used to start the state with the given name.
Clone this wiki locally