protected override void OnFormClosing(FormClosingEventArgs e) { string cfgpath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) + "\\rbxlegacy_config.txt"; base.OnFormClosing(e); LauncherFuncs.WriteConfigValues(cfgpath); GlobalVars.ReadyToLaunch = true; }
void QuickConfigureLoad(object sender, EventArgs e) { string cfgpath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) + "\\rbxlegacy_config.txt"; if (!File.Exists(cfgpath)) { LauncherFuncs.WriteConfigValues(cfgpath); } else { ReadConfigValues(cfgpath); } }
void ReadConfigValues(string cfgpath) { LauncherFuncs.ReadConfigValues(cfgpath); if (GlobalVars.UserID == 0) { GeneratePlayerID(); LauncherFuncs.WriteConfigValues(cfgpath); } else { textBox2.Text = GlobalVars.UserID.ToString(); } textBox1.Text = GlobalVars.PlayerName; }
void WriteConfigValues() { LauncherFuncs.WriteConfigValues("rbxlegacy_config.txt"); ConsolePrint("Configuration has been saved successfully.", 3); }