line(x1, y1, x2, y2, color, width) → {Phaser.BitmapData}
Draws a line between the coordinates given in the color and thickness specified.
Parameters
| Name | Type | Argument | Default | Description | 
|---|---|---|---|---|
x1 |  number | The x coordinate to start the line from.  |  ||
y1 |  number | The y coordinate to start the line from.  |  ||
x2 |  number | The x coordinate to draw the line to.  |  ||
y2 |  number | The y coordinate to draw the line to.  |  ||
color |  string |  <optional> |  '#fff' | The stroke color that the line will be drawn in.  |  
width |  number |  <optional> |  1 | The line thickness.  |  
Returns
This BitmapData object for method chaining.
- Source code: gameobjects/BitmapData.js (Line 1920)
 
Please login to continue.