From e6e30d2f270ba80fa44dd73b44496ba71da89686 Mon Sep 17 00:00:00 2001 From: Relintai Date: Sat, 2 Sep 2023 13:46:13 +0200 Subject: [PATCH] Backported from godot4: Disable NavigationMesh edge_max_length property by default Disables NavigationMesh edge_max_length property by default. - smix8 https://github.com/godotengine/godot/commit/c63125c31760b4896414cf6e8bd67234c072f9a5 --- doc/classes/NavigationMesh.xml | 4 ++-- scene/resources/navigation_mesh.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/classes/NavigationMesh.xml b/doc/classes/NavigationMesh.xml index 3a20a5396..20ebf4371 100644 --- a/doc/classes/NavigationMesh.xml +++ b/doc/classes/NavigationMesh.xml @@ -117,8 +117,8 @@ The maximum distance a simplfied contour's border edges should deviate the original raw contour. - - The maximum allowed length for contour edges along the border of the mesh. + + The maximum allowed length for contour edges along the border of the mesh. A value of [code]0.0[/code] disables this feature. [b]Note:[/b] While baking, this value will be rounded up to the nearest multiple of [member cell_size]. diff --git a/scene/resources/navigation_mesh.cpp b/scene/resources/navigation_mesh.cpp index b1a543b4b..9adabc885 100644 --- a/scene/resources/navigation_mesh.cpp +++ b/scene/resources/navigation_mesh.cpp @@ -649,7 +649,7 @@ NavigationMesh::NavigationMesh() { agent_max_slope = 45.0f; region_min_size = 2.0f; region_merge_size = 20.0f; - edge_max_length = 12.0f; + edge_max_length = 0.0f; edge_max_error = 1.3f; verts_per_poly = 6.0f; detail_sample_distance = 6.0f;