| | 1 | | using System; |
| | 2 | | using System.Linq; |
| | 3 | | using UnityEngine; |
| | 4 | |
|
| | 5 | | public class MapInfoHandler : IMapDataView |
| | 6 | | { |
| 0 | 7 | | public Vector2Int baseCoord { private set; get; } |
| 0 | 8 | | public string name { private set; get; } |
| 0 | 9 | | public string creator { private set; get; } |
| 0 | 10 | | public string description { private set; get; } |
| | 11 | |
|
| 0 | 12 | | public Vector2Int[] parcels { private set; get; } |
| | 13 | |
|
| | 14 | | public void SetMinimapSceneInfo(HotScenesController.HotSceneInfo sceneInfo) |
| | 15 | | { |
| 12 | 16 | | baseCoord = sceneInfo.baseCoords; |
| 12 | 17 | | name = sceneInfo.name; |
| 12 | 18 | | creator = sceneInfo.creator; |
| 12 | 19 | | description = sceneInfo.description; |
| 12 | 20 | | parcels = sceneInfo.parcels; |
| 12 | 21 | | } |
| | 22 | |
|
| | 23 | | public bool ContainCoords(Vector2Int coords) |
| | 24 | | { |
| 0 | 25 | | if (parcels == null) |
| 0 | 26 | | return false; |
| 0 | 27 | | return parcels.Contains(coords); |
| | 28 | | } |
| | 29 | | } |