public static void Make(ExtUITabstrip tabStrip) { UIHelper panelHelper = tabStrip.AddTabPage("Logging"); panelHelper.AddCheckbox( "Log asset loading times", ConfigUtil.Config.LogAssetLoadingTimes, val => { ConfigUtil.Config.LogAssetLoadingTimes = val; ConfigUtil.SaveConfig(); logAssetLoadingTimesToggle_.isEnabled = val; }); logAssetLoadingTimesToggle_ = panelHelper.AddCheckbox( "Per Mod", ConfigUtil.Config.LogPerModAssetLoadingTimes, val => { ConfigUtil.Config.LogPerModAssetLoadingTimes = val; ConfigUtil.SaveConfig(); }) as UIComponent; Settings.Indent(logAssetLoadingTimesToggle_); logAssetLoadingTimesToggle_ = panelHelper.AddCheckbox( "Log per mod OnCreated() times", ConfigUtil.Config.LogPerModOnCreatedTimes, val => { ConfigUtil.Config.LogPerModOnCreatedTimes = val; ConfigUtil.SaveConfig(); }) as UIComponent; }
public static void Make(ExtUITabstrip tabStrip) { UIHelper panelHelper = tabStrip.AddTabPage("Startup"); panelHelper.AddLabel("restart required to take effect.", textColor: Color.yellow); panelHelper.AddSpace(10); panelHelper.AddButton("Reset load orders", OnResetLoadOrdersClicked); panelHelper.AddCheckbox( "remove ad panels", ConfigUtil.Config.TurnOffSteamPanels, val => { ConfigUtil.Config.TurnOffSteamPanels = val; ConfigUtil.SaveConfig(); }); var c2 = panelHelper.AddCheckbox( "Improve content manager", ConfigUtil.Config.FastContentManager, val => { ConfigUtil.Config.FastContentManager = val; ConfigUtil.SaveConfig(); }) as UIComponent; c2.tooltip = "faster content manager"; var c3 = panelHelper.AddCheckbox( "Add harmony resolver", ConfigUtil.Config.AddHarmonyResolver, val => { ConfigUtil.Config.AddHarmonyResolver = val; ConfigUtil.SaveConfig(); }) as UICheckBox; var c4 = panelHelper.AddCheckbox( "Cache asset details for the tool.", ConfigUtil.Config.UGCCache, val => { ConfigUtil.Config.UGCCache = val; ConfigUtil.SaveConfig(); }) as UICheckBox; var c5 = panelHelper.AddCheckbox( "Hide steam download errors (Ignorance is bliss!)", ConfigUtil.Config.IgnoranceIsBliss, val => { ConfigUtil.Config.IgnoranceIsBliss = val; ConfigUtil.SaveConfig(); }) as UICheckBox; }
public static void Make(ExtUITabstrip tabStrip) { UIHelper panelHelper = tabStrip.AddTabPage("Developer"); panelHelper.AddCheckbox( "Soft assembly dependency", ConfigUtil.Config.SoftDLLDependancy, val => { ConfigUtil.Config.SoftDLLDependancy = val; ConfigUtil.SaveConfig(); }); panelHelper.AddButton("Ensure All", CheckSubsUtil.EnsureAll); //g.AddButton("RequestItemDetails", OnRequestItemDetailsClicked); //g.AddButton("QueryItems", OnQueryItemsClicked); panelHelper.AddButton("RunCallbacks", OnRunCallbacksClicked); var bufferedToggle = panelHelper.AddCheckbox("Buffered Log", Log.Buffered, (val) => Log.Buffered = val) as UICheckBox; bufferedToggle.eventVisibilityChanged += new PropertyChangedEventHandler <bool>((_, ___) => bufferedToggle.isChecked = Log.Buffered); }
public static void Make(ExtUITabstrip tabStrip) { UIHelper panelHelper = tabStrip.AddTabPage("Subscriptions"); UIButton button; UICheckBox checkBox; //g.AddButton("Perform All", OnPerformAllClicked); button = panelHelper.AddButton("Refresh workshop items (checks for bad items)", RequestItemDetails) as UIButton; button.tooltip = "checks for missing/partially downloaded/outdated items"; button = panelHelper.AddButton("unsubscribe from deprecated workshop items [EXPERIMENTAL] ", () => CheckSubsUtil.Instance.UnsubDepricated()) as UIButton; button.tooltip = "if steam does not return item path, i assume its deprecated."; button = panelHelper.AddButton("Resubscribe to all broken downloads (exits game) [EXPERIMENTAL]", CheckSubsUtil.ResubcribeExternally) as UIButton; button.tooltip = "less steam can hide problems. if you use less steam please click 'Refresh workshop items' to get all broken downloads"; button.isVisible = false; //hide for now. checkBox = panelHelper.AddCheckbox( "Delete unsubscribed items on startup", Config.DeleteUnsubscribedItemsOnLoad, val => { ConfigUtil.Config.DeleteUnsubscribedItemsOnLoad = val; ConfigUtil.SaveConfig(); }) as UICheckBox; button = panelHelper.AddButton("Delete Now", () => CheckSubsUtil.Instance.DeleteUnsubbed()) as UIButton; Settings.Pairup(checkBox, button); { var g = panelHelper.AddGroup("Broken downloads") as UIHelper; tfSteamPath_ = g.AddTextfield( text: "Steam Path: ", defaultContent: ConfigUtil.Config.SteamPath ?? "", eventChangedCallback: _ => { }, eventSubmittedCallback : delegate(string text) { if (CheckSteamPath(text)) { ConfigUtil.Config.SteamPath = text; ConfigUtil.SaveConfig(); } }) as UITextField; tfSteamPath_.width = 650; tfSteamPath_.tooltip = "Path to steam.exe"; g.AddButton("Redownload broken downloads [EXPERIMENTAL]", delegate() { try { var path = tfSteamPath_.text; if (CheckSteamPath(path)) { CheckSubsUtil.ReDownload(path); Prompt.Warning("Exit", "Please exit to desktop, wait for steam download to finish, and then start Cities skylines again.\n" + "Should this not work the first time, please try again."); } } catch (Exception ex) { ex.Log(); } }); } //b = g.AddButton("delete duplicates", OnPerformAllClicked) as UIButton; //b.tooltip = "when excluded mod is updated, and included duplicate of it is created"; }