Skip to main content

NavMesh

Used to access the World's baked NavMesh.

To get the NavMesh class, you must get its handler.

let NavMesh = instance.GetHandler("NavMesh")

You can then use the NavMesh property to access the NavMesh class.

Methods

Method NameReturn TypeParametersDescription
RaycastNavMeshHit?float3, float3, intTrace a line between two points on the NavMesh
CalculatePathboolfloat3, float3, int, NavPathCalculates a path between two points in a referenced NavPath, then returns if a complete or partial path was found
FindClosestEdgeNavMeshHit?float3, intLocates the closest NavMesh edge from a point on the NavMesh
SamplePositionNavMeshHit?float3, float, intFinds the nearest point based on the NavMesh within a specified range

Properties

Property NameTypeDescription
AllAreasintArea mask constant that includes all NavMesh areas