Scripting API

Scripting API

NavPath2D

Record in Abyss.Navigation, from Abyss.Navigation.

A path along a navmesh in 2D: the corners to walk, the start first and the end last.

public record NavPath2D

Constructors

public NavPath2D(IReadOnlyList<Vector2> Corners, bool Partial)

A path along a navmesh in 2D: the corners to walk, the start first and the end last.

Parameters

  • Corners: Its corners, empty where no path was found.
  • Partial: Whether the end could not be reached, and the path ends where it gets closest.

Properties

Corners

public IReadOnlyList<Vector2> Corners { get; init; }

Its corners, empty where no path was found.

Partial

public bool Partial { get; init; }

Whether the end could not be reached, and the path ends where it gets closest.

None

public static NavPath2D None { get; }

No path: an end was not on the navmesh.

Found

public bool Found { get; }

Whether a path was found, all the way or part of it.