private void frmMain_Load(object sender, EventArgs e) { LoadSettings(); if (!Directory.Exists(backupFolder)) { MessageBox.Show("You need to set your options"); frmOptions frmOptions = new frmOptions(this); frmOptions.Show(this); } string path = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments); DebugLog("Found My Documents path: " + path); // C:\Users\Computer User\Documents\My Games\SnowRunner\base\storage\cfe0fa55393049d0b040dc143ae99585 saveGamePathRoot = path + Path.DirectorySeparatorChar + "My Games" + Path.DirectorySeparatorChar + "SnowRunner" + Path.DirectorySeparatorChar + "base" + Path.DirectorySeparatorChar + "storage"; const string keyName = "HKEY_CURRENT_USER\\Software\\Epic Games\\Unreal Engine\\Identifiers"; accountId = (string)Registry.GetValue(keyName, "AccountId", "NONE"); if (accountId == "NONE") { DebugLog("Error: accountId not found in registry, is SnowRunner installed?"); } else { saveGamePath = saveGamePathRoot + Path.DirectorySeparatorChar + accountId; RefreshLists(); } }
private void optionsToolStripMenuItem_Click(object sender, EventArgs e) { frmOptions frmOptions = new frmOptions(this); frmOptions.ShowDialog(this); }