@@ -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
@@ -1290,8 +1287,6 @@ void GodotNavigationServer2D::physics_process(double p_delta_time) {
12901287 int _new_pm_edge_free_count = 0 ;
12911288 int _new_pm_obstacle_count = 0 ;
12921289
1293- // In c++ we can't be sure that this is performed in the main thread
1294- // even with mutable functions.
12951290 MutexLock lock (operations_mutex);
12961291 for (uint32_t i (0 ); i < active_maps.size (); i++) {
12971292 active_maps[i]->sync ();
@@ -1307,13 +1302,6 @@ void GodotNavigationServer2D::physics_process(double p_delta_time) {
13071302 _new_pm_edge_connection_count += active_maps[i]->get_pm_edge_connection_count ();
13081303 _new_pm_edge_free_count += active_maps[i]->get_pm_edge_free_count ();
13091304 _new_pm_obstacle_count += active_maps[i]->get_pm_obstacle_count ();
1310-
1311- // Emit a signal if a map changed.
1312- const uint32_t new_map_iteration_id = active_maps[i]->get_iteration_id ();
1313- if (new_map_iteration_id != active_maps_iteration_id[i]) {
1314- emit_signal (SNAME (" map_changed" ), active_maps[i]->get_self ());
1315- active_maps_iteration_id[i] = new_map_iteration_id;
1316- }
13171305 }
13181306
13191307 pm_region_count = _new_pm_region_count;
0 commit comments