protected void SetCurrentStateInternal(SimpleStateBase state)
        {
            CurrentState?.End();
            PrevState = CurrentState;

            CurrentState = state;
            CurrentState.Begin();
        }
        public void RegisterState(SimpleStateBase state)
        {
            if (States.ContainsKey(state.Name))
            {
                return;
            }

            state.Parent = this;
            States.Add(state.Name, state);
        }
 public void RemoveState(SimpleStateBase state)
 {
     RemoveState(state.Name);
 }
 public void Start(SimpleStateBase state)
 {
     Start(state.Name);
 }
 public void SetState(SimpleStateBase state)
 {
     SetState(state.Name);
 }