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


Show deprecated


Show deprecated

Path objects store the result of paths created by PathfindingService/CreatePath|PathfindingService:CreatePath().

Once a path object is created, you can call Path/ComputeAsync|Path:ComputeAsync() with a starting point and ending point. This will attempt to compute a valid path for a character to move along, based on default or custom parameters passed to PathfindingService/CreatePath|CreatePath(). If Path/ComputeAsync|ComputeAsync() successfully finds a path, the Path object will have a Path/Status value of Enum.PathStatus.Success. Otherwise the status will be Enum.PathStatus.NoPath which can occur if there are obstacles between the two points (and no way around) or if the points are inside of solid objects.

In addition to Path/ComputeAsync|ComputeAsync(), Path objects have the Path/GetWaypoints|GetWaypoints() method which returns a list of waypoints representing the points a character should follow in sequence to get from the beginning to the end of the path.

Finally, Path objects can be connected to the Path/Blocked|Path.Blocked event. This event will fire if, at any time during the path’s existence, the path is blocked. Note that this can occur behind a character moving along the path, not just in front of it.

See the Articles/Pathfinding|Pathfinding guide for details and examples on using pathfinding in Roblox.




[ReadOnly] [NotReplicated]

The success of the generated Path.



CheckOcclusionAsync ( int start )

[Yields] [Deprecated]

Checks if a path is blocked starting at a specific waypoint


GetWaypoints ( )

Returns an array of points in the path.