Phaser API Documentation

  Version: 
fillPoints(points, [closeShape], [closePath], [endIndex])

Description:

Fill the shape represented by the given array of points.

Pass closeShape to automatically close the shape by joining the last to the first point.

Pass closePath to automatically close the path before it is filled.

Parameters:

name type arguments Default description
points array | Array.<Phaser.Geom.Point>

The points to fill.

closeShape boolean <optional> false

When true, the shape is closed by joining the last point to the first point.

closePath boolean <optional> false

When true, the path is closed before being stroked.

endIndex number <optional>

The index of points to stop at. Defaults to points.length.

Returns:
Description:

This Game Object.

Since: 3.0.0