new job selection menu

This commit is contained in:
2023-03-28 11:19:23 +03:00
parent a3e82c8649
commit c392a38017
16 changed files with 97 additions and 112 deletions
+10
View File
@@ -6,6 +6,8 @@ public class UIManager : MonoBehaviour
[SerializeField]
public TimeSliderUI _timeSliderPrefab;
[SerializeField]
public JobSelectorUI _jobSelectorPrefab;
[SerializeField]
public GameObject _blurOverlay;
public static UIManager Instance { get; private set; }
@@ -30,6 +32,14 @@ public class UIManager : MonoBehaviour
timeSlider.ShowTimeSliderDialog(title, description, onCancel, onConfirm);
}
public void ShowJobSelectionDialog(string title, string description, Action onCancel, Action<TimeSpan> onConfirm)
{
var jobSelector = Instantiate(_jobSelectorPrefab, transform);
jobSelector.ShowJobSelectionDialog(title, description, onCancel, onConfirm);
}
public void Freeze()
{
_blurOverlay.SetActive(true);