Merge pull request #103784 from Dominrog/fix-visible-avoidance-debug

Fix visible avoidance debug rendering in NavigationRegion2D
This commit is contained in:
Thaddeus Crews 2025-03-13 08:57:15 -05:00
commit ba5edb2a77
No known key found for this signature in database
GPG Key ID: 62181B86FE9E5D84

View File

@ -181,7 +181,7 @@ void NavigationRegion2D::_notification(int p_what) {
case NOTIFICATION_DRAW: {
#ifdef DEBUG_ENABLED
if (is_inside_tree() && (Engine::get_singleton()->is_editor_hint() || NavigationServer2D::get_singleton()->get_debug_enabled()) && navigation_polygon.is_valid()) {
if (is_inside_tree() && (Engine::get_singleton()->is_editor_hint() || (NavigationServer2D::get_singleton()->get_debug_enabled() && NavigationServer2D::get_singleton()->get_debug_navigation_enabled())) && navigation_polygon.is_valid()) {
_update_debug_mesh();
_update_debug_edge_connections_mesh();
_update_debug_baking_rect();