diff --git a/OSM_Regions/RegionLoader.cs b/OSM_Regions/RegionLoader.cs index f60a4c5..c07c8fe 100644 --- a/OSM_Regions/RegionLoader.cs +++ b/OSM_Regions/RegionLoader.cs @@ -46,7 +46,7 @@ public class RegionLoader(float regionSize, string? importFolderPath = null, ILo if(line is null) continue; Node n = Node.Deserialize(line); - ret.Nodes.Add(n.ID, new Graph.Node(n.Lat, n.Lon)); + ret.Nodes.Add(n.ID, n); } logger?.LogDebug($"Loading Ways {waysPath}"); @@ -56,7 +56,7 @@ public class RegionLoader(float regionSize, string? importFolderPath = null, ILo if(line is null) continue; Way w = Way.Deserialize(line); - ret.Ways.Add(w.ID, new Graph.Way(w.Tags)); + ret.Ways.Add(w.ID, w); for (int i = 1; i < w.NodeIds.Count; i++) { ulong node1Id = w.NodeIds[i - 1]; @@ -74,6 +74,7 @@ public class RegionLoader(float regionSize, string? importFolderPath = null, ILo nodesReader.Dispose(); waysReader.Dispose(); + logger?.LogDebug($"Loaded Region {regionId} {ret.Nodes.Count} Nodes {ret.Ways.Count} Ways"); return ret; }