We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 829eec7 commit aa79333Copy full SHA for aa79333
1 file changed
Desktop.Common/DesktopFileService.cs
@@ -29,7 +29,15 @@ public DesktopFileService()
29
{
30
throw new NotImplementedException();
31
}
32
- SettingsBasePath = Path.Combine(OSBasePath, "Z2Randomizer");
+ var portableFile = Path.Combine(AppContext.BaseDirectory, "portable_mode.txt");
33
+ if (File.Exists(portableFile))
34
+ {
35
+ SettingsBasePath = Path.Combine(AppContext.BaseDirectory, "Settings");
36
+ }
37
+ else
38
39
+ SettingsBasePath = Path.Combine(OSBasePath, "Z2Randomizer");
40
41
SpriteBasePath = Path.Combine(AppContext.BaseDirectory, "Sprites");
42
PalacesBasePath = Path.GetDirectoryName(AppContext.BaseDirectory)! + Path.DirectorySeparatorChar;
43
Directory.CreateDirectory(SpriteBasePath);
0 commit comments