public void Update()
 {
     if (currentState != null)
     {
         currentState.DoActionInState();
     }
 }