PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience
Collapse Sidebar

PathWaypoint

PathWaypoint

A datatype constructed by a Enum/PathWaypointAction action and DataType/Vector3 position which is used by the PathService to create points along a generated path.

The code block below constructs a PathWaypoint variable with Vector2.new(10, 10, 10) as its position and Enum.PathWaypointAction.Walk as its action:

local pos = Vector3.new(10,10,10)
local waypoint = PathWaypoint.new(pos, Enum.PathWaypointAction.Walk)

Action

The Enum/PathWaypointAction|Action describes the action to take when this PathWaypoint is reached. It can be set to one of the following enum values:

Name Value Description

Walk

0

Walk action needed to reach the next waypoint

Jump

1

Jump action needed to reach the next waypoint

Constructors

PathWaypoint.new ( Vector3 position, Enum action )

Creates a new PathWaypoint object

Properties

Enum PathWaypoint.Action

The action to be performed at this waypoint

Vector3 PathWaypoint.Position

The 3D position of the waypoint