Fix to use startX and startY when generating grid points