@@ -293,13 +293,11 @@ COMMAND_2(map_set_active, RID, p_map, bool, p_active) {
293293 if (p_active) {
294294 if (!map_is_active (p_map)) {
295295 active_maps.push_back (map);
296- active_maps_iteration_id.push_back (map->get_iteration_id ());
297296 }
298297 } else {
299298 int map_index = active_maps.find (map);
300299 ERR_FAIL_COND (map_index < 0 );
301300 active_maps.remove_at (map_index);
302- active_maps_iteration_id.remove_at (map_index);
303301 }
304302}
305303
@@ -1192,7 +1190,6 @@ COMMAND_1(free, RID, p_object) {
11921190 int map_index = active_maps.find (map);
11931191 if (map_index >= 0 ) {
11941192 active_maps.remove_at (map_index);
1195- active_maps_iteration_id.remove_at (map_index);
11961193 }
11971194 map_owner.free (p_object);
11981195
@@ -1288,8 +1285,6 @@ void GodotNavigationServer2D::physics_process(double p_delta_time) {
12881285 int _new_pm_edge_free_count = 0 ;
12891286 int _new_pm_obstacle_count = 0 ;
12901287
1291- // In c++ we can't be sure that this is performed in the main thread
1292- // even with mutable functions.
12931288 MutexLock lock (operations_mutex);
12941289 for (uint32_t i (0 ); i < active_maps.size (); i++) {
12951290 active_maps[i]->sync ();
@@ -1305,13 +1300,6 @@ void GodotNavigationServer2D::physics_process(double p_delta_time) {
13051300 _new_pm_edge_connection_count += active_maps[i]->get_pm_edge_connection_count ();
13061301 _new_pm_edge_free_count += active_maps[i]->get_pm_edge_free_count ();
13071302 _new_pm_obstacle_count += active_maps[i]->get_pm_obstacle_count ();
1308-
1309- // Emit a signal if a map changed.
1310- const uint32_t new_map_iteration_id = active_maps[i]->get_iteration_id ();
1311- if (new_map_iteration_id != active_maps_iteration_id[i]) {
1312- emit_signal (SNAME (" map_changed" ), active_maps[i]->get_self ());
1313- active_maps_iteration_id[i] = new_map_iteration_id;
1314- }
13151303 }
13161304
13171305 pm_region_count = _new_pm_region_count;
0 commit comments