public PointInfo GetNextPoint()
        {
            counter += 1;

            var point = Points[counter];

            if (point == null)
            {
                var previousPoint = Points[counter - 1];
                Points[counter] = point = new PointInfo(previousPoint.coordinateX + DirectionX, previousPoint.coordinateY + DirectionY, Points.Length);
            }

            return point;
        }
示例#2
0
        public PointInfo GetNextPoint()
        {
            counter += 1;

            var point = Points[counter];

            if (point == null)
            {
                var previousPoint = Points[counter - 1];
                Points[counter] = point = new PointInfo(previousPoint.coordinateX + DirectionX, previousPoint.coordinateY + DirectionY, Points.Length);
            }

            return(point);
        }
 public void GeneratePoints(int amount)
 {
     Points = new PointInfo[amount];
     Points[0] = new PointInfo(X, Y, amount);
 }
示例#4
0
 public void GeneratePoints(int amount)
 {
     Points    = new PointInfo[amount];
     Points[0] = new PointInfo(X, Y, amount);
 }