public void OnValidate() { JuniperSystem.OnEditorUpdateIn( $"{typeof(MasterSceneController).FullName}::{nameof(SetBuildSettings)}", TimeSpan.FromSeconds(1), SetBuildSettings); }
private void LoadScenes_MenuItem() { JuniperSystem.EnsureFactory(); using (var prog = new UnityEditorProgressDialog("Loading scenes")) { this.Run(LoadAllScenesCoroutine(prog)); } }
private Task Stopper(Action <IProgress> actor, IProgress prog) { var onStoppedCompleter = new TaskCompletionSource <bool>(); void stopper(object _, EventArgs __) { Stopped -= stopper; onStoppedCompleter.SetResult(true); } Stopped += stopper; JuniperSystem.OnMainThread(() => actor(prog)); return(onStoppedCompleter.Task); }
private static void InstallJuniper() { UninstallJuniper(); if (!Find.Any(out JuniperSystem platform)) { platform = new GameObject("UserRig").Ensure <JuniperSystem>(); } platform.tag = "Player"; JuniperSystem.InstallSystem(true); global::UnityEditor.SceneManagement.EditorSceneManager.MarkSceneDirty( UnityEngine.SceneManagement.SceneManager.GetSceneAt(0)); }
private static void UninstallJuniper() { JuniperSystem.UninstallSystem(); }