Пример #1
0
        public bool MoveVectrialDown(int distance)
        {
            int locationV = ControlCom.GetVertical();
            int location  = locationV + distance;

            if (location <= 1000)
            {
                return(ControlCom.MoveVertical(location));
            }
            else
            {
                return(ControlCom.MoveVertical(1000));
            }
        }
Пример #2
0
        public bool MoveVectrialUp(int distance)
        {
            int locationV = ControlCom.GetVertical();
            int location  = locationV - distance;

            if (location >= 0)
            {
                return(ControlCom.MoveVertical(location));
            }
            else
            {
                return(ControlCom.MoveVertical(0));
            }
        }
Пример #3
0
 /// <summary>
 /// 获得垂直轴的位置
 /// </summary>
 /// <returns></returns>
 public int GetVertical()
 {
     return(ControlCom.GetVertical());
 }