示例#1
0
        public override void OnMouseMove(int positionX, int positionY)
        {
            Point point = _camera.ScreenToPoint(new Point(positionX, positionY));

            if (_choseBox.IsChosing)
            {
                _choseBox.SetBox(positionX, positionY);
            }
            CameraMotion type = _camera.GetMotion();

            if (type != CameraMotion.None)
            {
                GameCursor.SetType((CursorType)Enum.Parse(typeof(CursorType), type.ToString()));
            }
            else if (_commandTable.ContainCursor(point))
            {
                GameCursor.SetType(_commandTable.IsGettingTarget, false);
            }
            else
            {
                _map.OnMouseMove(point);
                GameCursor.SetType(_commandTable.IsGettingTarget, _map.CursorUnit != null);
            }
        }