Constructors

Accessors

Methods

  • Add a new state to the state machine.

    Parameters

    • config: StateConfig

      StateConfig. State names are Unique

    Returns default

  • Change states

    Parameters

    • stateName: string

      to enter

    • skipOnEnter: boolean = false

      set to true in order to call enterState without calling that state's onEnter() function

    Returns void

  • Send a signal to the statemachine to possibly change states

    Parameters

    • signal: string

      name of the signal

    • data: any = null

      optional data

    Returns void