Ejemplo n.º 1
0
 ///<summary>
 /// This is the constructor that will initialize the FSM and give it
 /// a unique name or id.
 ///</summary>
 public FSM(string name)
 {
     this.name         = name;
     this.currentState = null;
     stateMap          = new Dictionary <string, FSMState>();
 }
Ejemplo n.º 2
0
 public FSMAction(FSMState owner)
 {
     this.owner = owner;
 }
Ejemplo n.º 3
0
 ///<summary>
 /// This changes the state of the Object. It is not advisable to
 /// call this to change state.
 ///</summary>
 public void EnterState(FSMState state)
 {
     ProcessStateAction(state, delegate(FSMAction action) {
         action.OnEnter();
     });
 }