internal static void Request(bool ignoreSession = false) { if (!ignoreSession) { if (SessionState.GetBool(sessionState, false)) { return; } SessionState.SetBool(sessionState, true); } Task.Delay(2000).ContinueWith(t => { GameObject obj = new GameObject(); obj.hideFlags = HideFlags.HideAndDontSave; request = obj.AddComponent <HMSPluginUpdateRequest>(); request.StartRequest(ignoreSession); }, TaskScheduler.FromCurrentSynchronizationContext()); }
internal static void Request(bool ignoreSession = false) { if (!ignoreSession) { if (SessionState.GetBool(sessionState, false)) { return; } SessionState.SetBool(sessionState, true); HMSEditorUtils.HandleAssemblyDefinitions(HMSPluginSettings.Instance.Settings.GetBool(PluginToggleEditor.PluginEnabled, true)); } Task.Delay(2000).ContinueWith(t => { GameObject obj = new GameObject(); obj.hideFlags = HideFlags.HideAndDontSave; request = obj.AddComponent <HMSPluginUpdateRequest>(); request.StartRequest(ignoreSession); }, TaskScheduler.FromCurrentSynchronizationContext()); }