private void updateState(float timeStep)
    {
        if (IsState(MotorState.Dashing))
        {
            OnDashStay(m_DashState.GetDashProgress());

            if (m_DashState.GetDashProgress() >= 1.0f)
            {
                endDash();
            }
        }

        if (IsState(MotorState.Dashing))
        {
            return;
        }

        if (IsState(MotorState.CustomAction))
        {
            OnActionStay(m_ActionState.GetActionProgress());

            if (m_ActionState.GetActionProgress() >= 1.0f)
            {
                endAction();
            }
        }

        if (IsState(MotorState.CustomAction))
        {
            return;
        }

        if (IsState(MotorState.Jumping))
        {
            if (m_Motor.Velocity.y < 0)
            {
                endJump();
            }
        }

        if (IsGrounded())
        {
            if (!IsState(MotorState.OnLadder))
            {
                changeState(MotorState.OnGround);
            }
        }

        if (IsState(MotorState.WallSliding))
        {
            if (!IsAgainstWall())
            {
                if (m_Motor.Velocity.y < 0.0f)
                {
                    changeState(MotorState.Falling);
                }
                else
                {
                    changeState(MotorState.Jumping);
                }
            }
        }
    }