From 6b85bc9de29082044420f36a93dda77ff3d58d30 Mon Sep 17 00:00:00 2001 From: smix8 <52464204+smix8@users.noreply.github.com> Date: Mon, 10 Jun 2024 19:07:57 +0200 Subject: [PATCH] Fix NavigationRegion2D debug not clearing canvas item Fixes NavigationRegion2D debug not clearing canvas item on navigation mesh change. --- scene/2d/navigation_region_2d.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/scene/2d/navigation_region_2d.cpp b/scene/2d/navigation_region_2d.cpp index bad9de5daa4..9b3c7bb9ea8 100644 --- a/scene/2d/navigation_region_2d.cpp +++ b/scene/2d/navigation_region_2d.cpp @@ -458,6 +458,7 @@ void NavigationRegion2D::_update_debug_mesh() { return; } + rs->canvas_item_clear(debug_instance_rid); rs->mesh_clear(debug_mesh_rid); debug_mesh_dirty = false;