示例#1
0
        public IState changeState()
        {
            IState newState = null;
            if (timeElapsed > updateRating) {

                timeElapsed = 0;
                newState = new FreezerThinking(stateable);
            }
            return newState;
        }
示例#2
0
 public IState changeState()
 {
     IState newState = null;
     if (timeElapsed > updateRating) {
         //stateable.GetComponent<IMoveable> ().SetSpeed (Vector3.zero);
         timeElapsed = 0;
         newState = new FreezerThinking(stateable);
     }else if(fire){
         stateable.GetComponent<IMoveable> ().SetSpeed (Vector3.zero);
         newState = new FreezerShooting(stateable);
     }
     return newState;
 }