Example #1
0
 public void changeState(PlayerControl.playerStates newState)
 {
     if (currState == newState)
     {
         return;
     }
     else
     {
         playerControl.currState = newState;
         currState = playerControl.currState;
         return;
     }
 }
Example #2
0
 // Use this for initialization
 void Start()
 {
     playerControl = player.GetComponent <PlayerControl>();
     currState     = playerControl.currState;
 }
Example #3
0
 // Update is called once per frame
 void Update()
 {
     currState = playerControl.currState;
     jump();
 }