Exemplo n.º 1
0
 public void SetState(AbstractState state)
 {
     if (currentState != null) {
         currentState.Finish ();
     }
     currentState = state;
     currentState.Init (this);
     currentState.Start ();
     //propably we need run update in creating frame
     currentState.Update();
 }
Exemplo n.º 2
0
 public void ChangeState(AbstractState newState)
 {
     machine.SetState (newState);
 }