Constructors

Properties

mutable: boolean = false
points: Vector2[]

Methods

  • Get the length of the path

    Returns number

  • Get the point on the path at t Path can be described parametrically in the form of (x(t), y(t)) Path starts at t=0 and ends at t=1

    Parameters

    • t: number

      parameter

    • closed: boolean = false

      if true, the path is closed

    • Optionalsegment_index: number

      If segment_index (n) is defined, get the point at the nth segment. If segment_index (n) is defined, t can be outside of [0, 1] and will return the extrapolated point.

    Returns Vector2

    the position of the point