38 lines
1.5 KiB
C#
38 lines
1.5 KiB
C#
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
namespace Util
|
|
{
|
|
public class DataManager : MonoBehaviour
|
|
{
|
|
public GeoDataContainer GeoDataContainer;
|
|
|
|
private static IReadOnlyDictionary<string, IReadOnlyList<Coords>> _geoDataDictionary;
|
|
|
|
public static IReadOnlyDictionary<string, IReadOnlyList<Coords>> geoDataDictionary => _geoDataDictionary;
|
|
|
|
|
|
void Start()
|
|
{
|
|
_geoDataDictionary = GeoDataContainer.ToDictionary();
|
|
|
|
// var geoDatas = geoDataDictionary["CL"];
|
|
// foreach (var geoData in geoDatas)
|
|
// {
|
|
// foreach (var coords in geoData.coords)
|
|
// {
|
|
// Debug.Log($"======================GeoData X: {coords.x}========================");
|
|
// Debug.Log($"======================GeoData Y: {coords.y}========================");
|
|
// Debug.Log($"======================GeoData Z: {coords.z}========================");
|
|
// }
|
|
// }
|
|
// foreach (var coords in geoDatas.SelectMany(geoData => geoData.coords))
|
|
// {
|
|
// Debug.Log($"======================GeoData X: {coords.x}========================");
|
|
// Debug.Log($"======================GeoData Y: {coords.y}========================");
|
|
// Debug.Log($"======================GeoData Z: {coords.z}========================");
|
|
// }
|
|
}
|
|
}
|
|
}
|