Navmesh & Collision
Navmeshes define walkable space for pathfinding and movement constraints.
Components (quick overview)
Navmesh API reference
Navmesh :: class : Component {
// Project a point onto this navmesh.
// triangle_hint is an acceleration hint you can reuse for nearby queries.
try_find_closest_point_on_navmesh :: method(
to_point: v2,
result: ref v2,
triangle_hint: ref s64
) -> bool;
// Cast through the navmesh. Returns the endpoint and whether the query succeeded.
try_raycast :: method(position: v2, direction: v2) -> v2, bool;
// Queue a rebuild for the normal navmesh update.
mark_for_rebuild :: method();
// Rebuild now when a same-frame query needs the new geometry.
rebuild_immediately :: method() -> bool;
// Include only colliders on this entity and its descendants.
child_colliders_only: bool;
// Detect input changes and rebuild automatically.
enable_automatic_rebuilds: bool;
}Editor setup (building a navmesh)
Colliders and navmesh loops
Spawning on navmesh (clamp to reachable ground)
Rebuilding navmeshes immediately
Raycasting across a navmesh
Collider triggers
Proximity checks and custom hit logic
Scene query helpers
Trigger volume (enter / stay / exit)
Pickups (closest in range)
Fast movement "hits" (simple sub-stepping)
Last updated