Phaser API Documentation

  Version: 

Member of: Phaser.Curves.Line

draw(graphics)

Description:

Draws this curve on the given Graphics object.

The curve is drawn using Graphics.lineBetween so will be drawn at whatever the present Graphics line color is. The Graphics object is not cleared before the draw, so the curve will appear on-top of anything else already rendered to it.

Parameters:

name type description
graphics Phaser.GameObjects.Graphics

The Graphics instance onto which this curve will be drawn.

Returns:
Description:

The Graphics object to which the curve was drawn.

Examples:
Since: 3.0.0
Source: src/curves/LineCurve.js (Line 236)