net.dreditor.maps 0.0.0-stage → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (132) hide show
  1. package/.attestation.p7m +0 -0
  2. package/CharacterMapMarkerUI.cs +95 -0
  3. package/CharacterMapMarkerUI.cs.meta +11 -0
  4. package/CharacterMapUITab.cs +172 -0
  5. package/CharacterMapUITab.cs.meta +11 -0
  6. package/ClearMapAreaData.cs +23 -0
  7. package/ClearMapAreaData.cs.meta +11 -0
  8. package/ClearMapInstanceData.cs +36 -0
  9. package/ClearMapInstanceData.cs.meta +11 -0
  10. package/ControlFastTravel.cs +57 -0
  11. package/ControlFastTravel.cs.meta +11 -0
  12. package/DREditor.Maps.asmdef +24 -0
  13. package/DREditor.Maps.asmdef.meta +7 -0
  14. package/DiscoverData.cs +23 -0
  15. package/DiscoverData.cs.meta +11 -0
  16. package/DiscoverableBase.cs +24 -0
  17. package/DiscoverableBase.cs.meta +11 -0
  18. package/FastTravelController.cs +36 -0
  19. package/FastTravelController.cs.meta +11 -0
  20. package/FastTravelData.cs +25 -0
  21. package/FastTravelData.cs.meta +11 -0
  22. package/FastTravelMarker.cs +107 -0
  23. package/FastTravelMarker.cs.meta +13 -0
  24. package/IDHolder.cs +47 -0
  25. package/IDHolder.cs.meta +11 -0
  26. package/IEntryLoader.cs +19 -0
  27. package/IEntryLoader.cs.meta +11 -0
  28. package/IMapManager.cs +27 -0
  29. package/IMapManager.cs.meta +11 -0
  30. package/IPlaceMarker.cs +26 -0
  31. package/IPlaceMarker.cs.meta +11 -0
  32. package/IPlaceOptionHolder.cs +53 -0
  33. package/IPlaceOptionHolder.cs.meta +11 -0
  34. package/MapAreaData.cs +53 -0
  35. package/MapAreaData.cs.meta +11 -0
  36. package/MapAreaEntry.cs +55 -0
  37. package/MapAreaEntry.cs.meta +11 -0
  38. package/MapAreaManager.cs +194 -0
  39. package/MapAreaManager.cs.meta +11 -0
  40. package/MapBaseData.cs +66 -0
  41. package/MapBaseData.cs.meta +11 -0
  42. package/MapData.cs +35 -0
  43. package/MapData.cs.meta +11 -0
  44. package/MapDatabase.cs +133 -0
  45. package/MapDatabase.cs.meta +11 -0
  46. package/MapEntry.cs +77 -0
  47. package/MapEntry.cs.meta +11 -0
  48. package/MapEntryChange.cs +321 -0
  49. package/MapEntryChange.cs.meta +11 -0
  50. package/MapEntryChanger.cs +45 -0
  51. package/MapEntryChanger.cs.meta +11 -0
  52. package/MapHoverSelector.cs +161 -0
  53. package/MapHoverSelector.cs.meta +11 -0
  54. package/MapManager.cs +288 -0
  55. package/MapManager.cs.meta +11 -0
  56. package/MapManagerBase.cs +260 -0
  57. package/MapManagerBase.cs.meta +11 -0
  58. package/MapMarkerSelectable.cs +71 -0
  59. package/MapMarkerSelectable.cs.meta +11 -0
  60. package/MapObjectiveData.cs +28 -0
  61. package/MapObjectiveData.cs.meta +11 -0
  62. package/MapSaveManager.cs +63 -0
  63. package/MapSaveManager.cs.meta +11 -0
  64. package/MapTabUIHandler.cs +98 -0
  65. package/MapTabUIHandler.cs.meta +11 -0
  66. package/MapUITab.cs +26 -0
  67. package/MapUITab.cs.meta +11 -0
  68. package/MapUtility.cs +183 -0
  69. package/MapUtility.cs.meta +11 -0
  70. package/MarkerData.cs +25 -0
  71. package/MarkerData.cs.meta +11 -0
  72. package/MarkerDatabase.cs +57 -0
  73. package/MarkerDatabase.cs.meta +11 -0
  74. package/MarkerUtility.cs +48 -0
  75. package/MarkerUtility.cs.meta +11 -0
  76. package/MarkerVessel.cs +38 -0
  77. package/MarkerVessel.cs.meta +11 -0
  78. package/PlaceData.cs +27 -0
  79. package/PlaceData.cs.meta +11 -0
  80. package/PlaceEntry.cs +83 -0
  81. package/PlaceEntry.cs.meta +11 -0
  82. package/PlaceManager.cs +293 -0
  83. package/PlaceManager.cs.meta +11 -0
  84. package/PlaceMapUITab.cs +203 -0
  85. package/PlaceMapUITab.cs.meta +11 -0
  86. package/Samples~/Clear_Map_Area_Data_Event.prefab +52 -0
  87. package/Samples~/Clear_Map_Area_Data_Event.prefab.meta +7 -0
  88. package/Samples~/Clear_Map_Instance_Data.prefab +56 -0
  89. package/Samples~/Clear_Map_Instance_Data.prefab.meta +7 -0
  90. package/Samples~/DRE_Map_UI.unity +461 -0
  91. package/Samples~/DRE_Map_UI.unity.meta +7 -0
  92. package/Samples~/Map_Entry_Changer.prefab +52 -0
  93. package/Samples~/Map_Entry_Changer.prefab.meta +7 -0
  94. package/Samples~/Map_Marker_Selectable_ETemplate.prefab +126 -0
  95. package/Samples~/Map_Marker_Selectable_ETemplate.prefab.meta +7 -0
  96. package/Samples~/Map_Tab_UI_Handler_Shell.prefab +134 -0
  97. package/Samples~/Map_Tab_UI_Handler_Shell.prefab.meta +7 -0
  98. package/Samples~/Map_Tab_UI_Handler_Template.prefab +404 -0
  99. package/Samples~/Map_Tab_UI_Handler_Template.prefab.meta +7 -0
  100. package/Samples~/Map_UI_Canvas_Shell.prefab +842 -0
  101. package/Samples~/Map_UI_Canvas_Shell.prefab.meta +7 -0
  102. package/Samples~/Map_UI_Canvas_Template.prefab +996 -0
  103. package/Samples~/Map_UI_Canvas_Template.prefab.meta +7 -0
  104. package/Samples~/Map_UI_Controls_ETemplate.prefab +538 -0
  105. package/Samples~/Map_UI_Controls_ETemplate.prefab.meta +7 -0
  106. package/Samples~/Map_UI_GO_FT_ETemplate.prefab +78 -0
  107. package/Samples~/Map_UI_GO_FT_ETemplate.prefab.meta +7 -0
  108. package/Samples~/Map_UI_Place_Place_Name_ETemplate.prefab +181 -0
  109. package/Samples~/Map_UI_Place_Place_Name_ETemplate.prefab.meta +7 -0
  110. package/Samples~/Map_UI_Place_Tab_Shell.prefab +57 -0
  111. package/Samples~/Map_UI_Place_Tab_Shell.prefab.meta +7 -0
  112. package/Samples~/Map_UI_Place_Tab_Template.prefab +806 -0
  113. package/Samples~/Map_UI_Place_Tab_Template.prefab.meta +7 -0
  114. package/Samples~/Map_UI_Place_Tab_UI_ETemplate.prefab +1265 -0
  115. package/Samples~/Map_UI_Place_Tab_UI_ETemplate.prefab.meta +7 -0
  116. package/Samples~/Map_UI_Reticle_ETemplate.prefab +78 -0
  117. package/Samples~/Map_UI_Reticle_ETemplate.prefab.meta +7 -0
  118. package/Samples~/Map_UI_Student_Tab_Shell.prefab +267 -0
  119. package/Samples~/Map_UI_Student_Tab_Shell.prefab.meta +7 -0
  120. package/Samples~/Map_UI_Student_Tab_Template.prefab +544 -0
  121. package/Samples~/Map_UI_Student_Tab_Template.prefab.meta +7 -0
  122. package/Samples~/Map_UI_Student_Tab_UI_Shell.prefab +90 -0
  123. package/Samples~/Map_UI_Student_Tab_UI_Shell.prefab.meta +7 -0
  124. package/Samples~/Map_UI_Student_Tab_UI_Template.prefab +2031 -0
  125. package/Samples~/Map_UI_Student_Tab_UI_Template.prefab.meta +7 -0
  126. package/Samples~/Map_UI_Title_ETemplate.prefab +672 -0
  127. package/Samples~/Map_UI_Title_ETemplate.prefab.meta +7 -0
  128. package/Samples~/Place_Template.prefab +200 -0
  129. package/Samples~/Place_Template.prefab.meta +7 -0
  130. package/package.json +43 -4
  131. package/package.json.meta +7 -0
  132. package/README.md +0 -3
@@ -0,0 +1,11 @@
1
+ fileFormatVersion: 2
2
+ guid: 9fff4b2eee3a4944eabcb52cf31c2338
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -0,0 +1,45 @@
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ using DREditor.DialogueEventHandling;
3
+ using DREditor.Services;
4
+
5
+ namespace DREditor.Maps
6
+ {
7
+ /// <summary>
8
+ ///
9
+ /// </summary>
10
+ [CustomDialogueEvent("")]
11
+ [ClassHeader(nameof(DialogueEventHandler) +
12
+ "\n\n")]
13
+ public class MapEntryChanger : DialogueEventHandler
14
+ {
15
+ /// <inheritdoc/>
16
+ protected override void OnDialogueEventTriggered(object o = null)
17
+ {
18
+ if (o is MapEntryChange change && change != null)
19
+ ChangeMapEntry(change);
20
+ }
21
+
22
+ /// <summary>
23
+ ///
24
+ /// </summary>
25
+ /// <param name="change"></param>
26
+ protected virtual void ChangeMapEntry(MapEntryChange change)
27
+ {
28
+ if (change.unlockArea != "")
29
+ ServiceLocator.GetService<IMapManager>().AddUnlockedArea(change.unlockArea);
30
+
31
+ if (change.Entry.AreaEntries.Count == 0)
32
+ return;
33
+
34
+ change.Entry.SetUnlockedAreas(ServiceLocator.GetService<IMapManager>().GetInstanceData().UnlockedAreas);
35
+
36
+ ServiceLocator.GetService<IMapManager>().SetInstanceData(change.Entry);
37
+ }
38
+
39
+
40
+ /// <summary>
41
+ ///
42
+ /// </summary>
43
+ protected virtual void Reset() => SetDefaultEventString("MapEntryChange");
44
+ }
45
+ }
@@ -0,0 +1,11 @@
1
+ fileFormatVersion: 2
2
+ guid: 492b102bb8b863a4d98e80d4459bb610
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -0,0 +1,161 @@
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ #if DOTWEEN
3
+ using DG.Tweening;
4
+ #endif
5
+ using DREditor.EventObjects;
6
+ using DREditor.Services;
7
+ using System.Collections;
8
+ using UnityEngine;
9
+ using UnityEngine.Events;
10
+ using UnityEngine.EventSystems;
11
+ using UnityEngine.UI;
12
+
13
+ namespace DREditor.Maps
14
+ {
15
+ /// <summary>
16
+ ///
17
+ /// </summary>
18
+ [ClassHeader(nameof(ServiceHolder<MapHoverSelector>) + " for type: " + nameof(MapHoverSelector) +
19
+ "\n\n")]
20
+ public class MapHoverSelector : ServiceHolder<MapHoverSelector>
21
+ {
22
+ /// <summary>
23
+ ///
24
+ /// </summary>
25
+ [Space]
26
+ [Divider]
27
+ [Tooltip("")]
28
+ [SerializeField] protected Image selectionImage = null;
29
+
30
+ /// <summary>
31
+ ///
32
+ /// </summary>
33
+ [Tooltip("")]
34
+ [SerializeField] protected RectTransform reticleTransform = null;
35
+
36
+ /// <summary>
37
+ ///
38
+ /// </summary>
39
+ [Tooltip("")]
40
+ [SerializeField] protected GameObject fastTravelUIObject = null;
41
+
42
+ /// <summary>
43
+ ///
44
+ /// </summary>
45
+ [Tooltip("")]
46
+ [SerializeField] protected BoolWithEvent canFastTravel = null;
47
+
48
+ /// <summary>
49
+ ///
50
+ /// </summary>
51
+ [Tooltip("")]
52
+ [SerializeField] protected float hoverDuration = 1;
53
+
54
+
55
+ [Header("")]
56
+ [SerializeField] protected UnityEvent onHoverComplete = null;
57
+
58
+
59
+ /// <summary>
60
+ ///
61
+ /// </summary>
62
+ protected PlaceManager currentPlace = null;
63
+
64
+ /// <summary>
65
+ ///
66
+ /// </summary>
67
+ /// <remarks></remarks>
68
+ protected Vector3 lastPosition = Vector3.zero;
69
+
70
+
71
+ /// <summary>
72
+ ///
73
+ /// </summary>
74
+ /// <param name="place"></param>
75
+ public virtual void AnimateToHoveredPlace(PlaceManager place) => StartCoroutine(WaitUntilMapLoadedToAnimate(place));
76
+
77
+ /// <summary>
78
+ ///
79
+ /// </summary>
80
+ /// <param name="place"></param>
81
+ /// <returns></returns>
82
+ protected virtual IEnumerator WaitUntilMapLoadedToAnimate(PlaceManager place)
83
+ {
84
+ yield return new WaitUntil(() => ServiceLocator.HasService<MapAreaManager>()
85
+ && ServiceLocator.GetService<MapAreaManager>() != null);
86
+
87
+ AnimateToPlace(place);
88
+ }
89
+
90
+ /// <summary>
91
+ ///
92
+ /// </summary>
93
+ /// <param name="place"></param>
94
+ protected virtual void AnimateToPlace(PlaceManager place)
95
+ {
96
+ if (!ServiceLocator.HasService<MapAreaManager>() || place == null)
97
+ return;
98
+
99
+ GameObject areaGameObject = ServiceLocator.GetService<MapAreaManager>().gameObject;
100
+
101
+ if (selectionImage != null && EventSystem.current.currentSelectedGameObject != null)
102
+ selectionImage.transform.position = EventSystem.current.currentSelectedGameObject.transform.position;
103
+
104
+ Vector3 toPosition = reticleTransform.position + (areaGameObject.transform.position - place.transform.position);
105
+
106
+ if (currentPlace != null && lastPosition == toPosition)
107
+ {
108
+ lastPosition = areaGameObject.transform.position;
109
+
110
+ return;
111
+ }
112
+
113
+ AnimateToObject(areaGameObject, toPosition, place);
114
+ }
115
+
116
+ /// <summary>
117
+ ///
118
+ /// </summary>
119
+ /// <param name="areaGameObject"></param>
120
+ /// <param name="toPosition"></param>
121
+ /// <param name="place"></param>
122
+ protected virtual void AnimateToObject(GameObject areaGameObject, Vector3 toPosition, PlaceManager place)
123
+ {
124
+ #if DOTWEEN
125
+ areaGameObject.transform.DOKill();
126
+
127
+ areaGameObject.transform.DOMove(toPosition, hoverDuration)
128
+ .SetUpdate(true)
129
+ .OnComplete(InvokeHoverComplete);
130
+ #endif
131
+ if (currentPlace != null)
132
+ currentPlace.Deselect();
133
+
134
+ place.Select();
135
+
136
+ lastPosition = toPosition;
137
+
138
+ currentPlace = place;
139
+
140
+ fastTravelUIObject.SetActive(PlaceIsFastTravelable() && canFastTravel.Value);
141
+ }
142
+
143
+ /// <summary>
144
+ ///
145
+ /// </summary>
146
+ protected virtual void InvokeHoverComplete() => onHoverComplete?.Invoke();
147
+
148
+ /// <summary>
149
+ ///
150
+ /// </summary>
151
+ /// <returns></returns>
152
+ public virtual PlaceManager GetCurrentPlace() => currentPlace;
153
+
154
+ /// <summary>
155
+ ///
156
+ /// </summary>
157
+ /// <returns></returns>
158
+ public virtual bool PlaceIsFastTravelable() => currentPlace != null && currentPlace.Data.fastTravelable &&
159
+ currentPlace.GetEntryInstance().enableFastTravelForThisEntryInstance;
160
+ }
161
+ }
@@ -0,0 +1,11 @@
1
+ fileFormatVersion: 2
2
+ guid: 7405e10bbc2332f4a96b22fe345d756c
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
package/MapManager.cs ADDED
@@ -0,0 +1,288 @@
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ using DREditor.RoomLoading;
3
+ using DREditor.Services;
4
+ using System.Collections;
5
+ using UnityEngine;
6
+ using UnityEngine.Events;
7
+ using UnityEngine.EventSystems;
8
+ using UnityEngine.InputSystem;
9
+ using static UnityEngine.InputSystem.InputAction;
10
+
11
+ namespace DREditor.Maps
12
+ {
13
+ /// <summary>
14
+ ///
15
+ /// </summary>
16
+ [ClassHeader(nameof(ServiceHolder<IMapManager>) + " for type: " + nameof(IMapManager) +
17
+ "\n\n")]
18
+ public class MapManager : MapManagerBase
19
+ {
20
+ /// <summary>
21
+ ///
22
+ /// </summary>
23
+ [Space]
24
+ [Tooltip("")]
25
+ [SerializeField] protected InputActionReference submit = null;
26
+
27
+ /// <summary>
28
+ ///
29
+ /// </summary>
30
+ [Tooltip("")]
31
+ [SerializeField] protected InputActionReference navigate = null;
32
+
33
+ /// <summary>
34
+ ///
35
+ /// </summary>
36
+ [Tooltip("")]
37
+ [SerializeField] protected InputActionReference shuffleLeft = null;
38
+
39
+ /// <summary>
40
+ ///
41
+ /// </summary>
42
+ [Tooltip("")]
43
+ [SerializeField] protected InputActionReference shuffleRight = null;
44
+
45
+ /// <summary>
46
+ ///
47
+ /// </summary>
48
+ [Tooltip("")]
49
+ [SerializeField] protected InputActionReference rightClick = null;
50
+
51
+ /// <summary>
52
+ ///
53
+ /// </summary>
54
+ [Tooltip("")]
55
+ [SerializeField] protected bool giveAllMapsOnStart = false;
56
+
57
+
58
+ [Header("")]
59
+ [SerializeField] protected UnityEvent OnTeleportMapUI;
60
+
61
+
62
+ /// <summary>
63
+ ///
64
+ /// </summary>
65
+ protected bool changingArea = false;
66
+
67
+
68
+ /// <summary>
69
+ ///
70
+ /// </summary>
71
+ protected virtual void ActivateControls()
72
+ {
73
+ submit.action.performed += OnPlaceSelected;
74
+
75
+ navigate.action.performed += NavigateSelectVisual;
76
+
77
+ shuffleLeft.action.started += DecreaseArea;
78
+
79
+ shuffleRight.action.started += IncreaseArea;
80
+
81
+ rightClick.action.started += OnChangeTab;
82
+ }
83
+
84
+ /// <summary>
85
+ ///
86
+ /// </summary>
87
+ protected virtual void DeactivateControls()
88
+ {
89
+ submit.action.performed -= OnPlaceSelected;
90
+
91
+ navigate.action.performed -= NavigateSelectVisual;
92
+
93
+ shuffleLeft.action.started -= DecreaseArea;
94
+
95
+ shuffleRight.action.started -= IncreaseArea;
96
+
97
+ rightClick.action.started -= OnChangeTab;
98
+ }
99
+
100
+ /// <summary>
101
+ ///
102
+ /// </summary>
103
+ /// <param name="ctx"></param>
104
+ protected virtual void OnChangeTab(CallbackContext ctx)
105
+ {
106
+ if (!ServiceLocator.HasService(out MapTabUIHandler tabHandler))
107
+ return;
108
+
109
+ if (tabHandler.IsOnDefaultTab())
110
+ placeOptionHolder.DisableSelectableOptions();
111
+
112
+ tabHandler.UpdateTab();
113
+
114
+ if (tabHandler.IsOnDefaultTab())
115
+ {
116
+ tabHandler.InitializeTab();
117
+
118
+ if (tabHandler.IsOnDefaultTab())
119
+ AnimateToHoveredPlace();
120
+
121
+ PopulateMapUIText(0);
122
+ }
123
+ else
124
+ UpdateMapUI();
125
+ }
126
+
127
+ /// <summary>
128
+ ///
129
+ /// </summary>
130
+ /// <param name="ctx"></param>
131
+ protected virtual void OnPlaceSelected(CallbackContext ctx)
132
+ {
133
+ UnityEngine.Debug.Log("REPORT: TELEPORT REQUESTED");
134
+
135
+ if (ServiceLocator.GetService<MapHoverSelector>().PlaceIsFastTravelable())
136
+ EvaluateTeleportingTo(ServiceLocator.GetService<MapHoverSelector>().GetCurrentPlace());
137
+ else
138
+ UnityEngine.Debug.Log("REPORT: TELEPORT REQUEST UNSUCCESSFUL, PLACE WAS NOT FAST TRAVELABLE.");
139
+ }
140
+
141
+ /// <summary>
142
+ ///
143
+ /// </summary>
144
+ /// <param name="currentPlace"></param>
145
+ protected virtual void EvaluateTeleportingTo(PlaceManager currentPlace)
146
+ {
147
+ DeactivateControls();
148
+
149
+ if (ServiceLocator.HasService(out ITeleporter teleporter) &&
150
+ teleporter.RequestTeleport(currentPlace.Data.sceneName, currentPlace.Data.fastTravelIndex))
151
+ {
152
+ UnityEngine.Debug.Log("REPORT: TELEPORT REQUEST SUCCESSFUL");
153
+
154
+ LeaveProcess();
155
+
156
+ OnTeleportMapUI?.Invoke();
157
+
158
+ Time.timeScale = 1;
159
+ }
160
+ else
161
+ {
162
+ UnityEngine.Debug.Log("REPORT: TELEPORT REQUEST UNSUCCESSFUL");
163
+
164
+ ActivateControls();
165
+ }
166
+ }
167
+
168
+ /// <summary>
169
+ ///
170
+ /// </summary>
171
+ /// <param name="ctx"></param>
172
+ protected virtual void IncreaseArea(CallbackContext ctx)
173
+ {
174
+ if (changingArea || currentAreaIndex == mapDatabase.ValidFloorList(InstanceData.UnlockedAreas).Count - 1)
175
+ return;
176
+
177
+ currentAreaIndex++;
178
+
179
+ ChangeArea();
180
+ }
181
+
182
+ /// <summary>
183
+ ///
184
+ /// </summary>
185
+ /// <param name="ctx"></param>
186
+ protected virtual void DecreaseArea(CallbackContext ctx)
187
+ {
188
+ if (changingArea || currentAreaIndex == 0)
189
+ return;
190
+
191
+ currentAreaIndex--;
192
+
193
+ ChangeArea();
194
+ }
195
+
196
+ /// <summary>
197
+ ///
198
+ /// </summary>
199
+ protected virtual IEnumerator AreaWait()
200
+ {
201
+ yield return new WaitForEndOfFrame();
202
+
203
+ changingArea = false;
204
+ }
205
+
206
+
207
+ /// <summary>
208
+ ///
209
+ /// </summary>
210
+ protected override void Start()
211
+ {
212
+ base.Start();
213
+
214
+ if (giveAllMapsOnStart)
215
+ DebugGivePlayerAllMaps();
216
+ }
217
+
218
+ /// <summary>
219
+ ///
220
+ /// </summary>
221
+ protected virtual void DebugGivePlayerAllMaps()
222
+ {
223
+ foreach (var o in mapDatabase.floors)
224
+ InstanceData.UnlockedAreas.Add(o.name);
225
+ }
226
+
227
+
228
+ /// <summary>
229
+ ///
230
+ /// </summary>
231
+ /// <remarks></remarks>
232
+ public virtual void StartDisplayingUI()
233
+ {
234
+ if (mapDatabase != null && mapDatabase.floors.Count > 0)
235
+ ChangeArea();
236
+ else
237
+ UnityEngine.Debug.LogWarning($"ALERT: {ToString()}: Couldn't Populate UI due to Map Database not having information.");
238
+ }
239
+
240
+ /// <summary>
241
+ ///
242
+ /// </summary>
243
+ protected virtual void ChangeArea()
244
+ {
245
+ changingArea = true;
246
+
247
+ DeactivateControls();
248
+
249
+ UpdateMapUI();
250
+
251
+ ActivateControls();
252
+
253
+ StartCoroutine(AreaWait());
254
+ }
255
+
256
+
257
+ /// <summary>
258
+ ///
259
+ /// </summary>
260
+ /// <remarks></remarks>
261
+ public virtual void LeaveProcess()
262
+ {
263
+ DeactivateControls();
264
+
265
+ EventSystem.current.SetSelectedGameObject(null);
266
+
267
+ DestroyAreaUI();
268
+
269
+ shiftNumber = 0;
270
+
271
+ ServiceLocator.GetService<MapTabUIHandler>().ShowDefaultTab();
272
+
273
+ placeOptionHolder.DisableSelectableOptions();
274
+ }
275
+
276
+
277
+ /// <summary>
278
+ ///
279
+ /// </summary>
280
+ /// <param name="shiftNum"></param>
281
+ protected override void PopulateMapUIText(int shiftNum)
282
+ {
283
+ base.PopulateMapUIText(shiftNum);
284
+
285
+ placeOptionHolder.EnableSelectablesOnValidText();
286
+ }
287
+ }
288
+ }
@@ -0,0 +1,11 @@
1
+ fileFormatVersion: 2
2
+ guid: e4f0cd550b032bc4fb6f8c48b2326adf
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant: