Constructor. Creates an EntityStateMachine.
The entity whose state machine this is
Add a state to this state machine.
The name of this state - used to identify it later in the changeState method call.
The state.
This state machine, so methods can be chained.
Create a new state in this state machine.
The name of the new state - used to identify it later in the changeState method call.
The new EntityState object that is the state. This will need to be configured with the appropriate component providers.
Generated using TypeDoc
This is a state machine for an entity. The state machine manages a set of states, each of which has a set of component providers. When the state machine changes the state, it removes components associated with the previous state and adds components associated with the new state.