/Engine/Source/Runtime/GeometryCore/Public/DynamicMesh/ColliderMesh.h
Find the TriangleID closest to P on the collider mesh, and distance to it, within distance MaxDist, or return InvalidID. UseGetSourceTriangleID()to map the TriangleID back to the source mesh. Use MeshQueries.TriangleDistance() to get more information.
int FindNearestTriangle ( const FVector3d & Point, double & NearestDistSqrOut, const [IMeshSpatial::FQueryOptions](API\Runtime\GeometryCore\Spatial\IMeshSpatial\FQueryOptions) & Options ) const