phaser/v3/typings/geom/line/GetPointsOnLine.d.ts
2017-01-16 22:43:07 +01:00

10 lines
589 B
TypeScript

/**
* Using Bresenham's line algorithm this will return an array of all coordinates on this line.
* The start and end points are rounded before this runs as the algorithm works on integers.
*
* @method Phaser.Line#coordinatesOnLine
* @param {number} [stepRate=1] - How many steps will we return? 1 = every coordinate on the line, 2 = every other coordinate, etc.
* @param {array} [results] - The array to store the results in. If not provided a new one will be generated.
* @return {array} An array of coordinates.
*/
export default function (line: any, stepRate: any, results: any): any;