Check if user path argument exists

This commit is contained in:
Tixx 2024-12-06 18:49:23 +01:00
parent ffc36e7f3d
commit a63f1bd27c
No known key found for this signature in database
GPG Key ID: EC6E7A2BAABF0B8C

View File

@ -31,7 +31,7 @@ std::string GetGamePath() {
static std::string Path; static std::string Path;
if (!Path.empty()) if (!Path.empty())
return Path; return Path;
if (options.user_path) { if (options.user_path && std::filesystem::exists(options.user_path)) {
Path = options.user_path; Path = options.user_path;
} else { } else {
HKEY hKey; HKEY hKey;