You can listen for changes in the tutorials system so that you can respond appropriately, such as updating the UI, by implementing the IObserver pattern, or use the SystemObserver<T> type which handles it for you.
1
2
3
4
5
vardisposer=SystemObserver<TutorialsSystem>.Create(tutorialsSystem,system=>{Instance.Logger.Info($"System updated.");// Update UI elements etc as necessary here...});
vartutorials=tutorialsSystem.GetAllTutorials();foreach(vartutorialintutorials){Debug.Log($"Tutorial {tutorial.Id}");Debug.Log($"Step {tutorial.Current} of {tutorial.Max}");if(tutorial.State==TutorialState.Completed){varcompletedAt=DateTimeOffset.FromUnixTimeMilliseconds(tutorial.CompleteTimeSec).DateTime;Debug.Log($"Completed at {completedAt.ToShortDateString()}");}}