Fix .git folder check and GetGamePath()

This commit is contained in:
Tixx 2025-06-08 13:45:09 +02:00
parent 6c740e2562
commit 8b96ffb098
No known key found for this signature in database
GPG Key ID: EC6E7A2BAABF0B8C
2 changed files with 2 additions and 2 deletions

View File

@ -95,7 +95,7 @@ std::wstring GetGamePath() {
std::string Ver = CheckVer(GetGameDir()); std::string Ver = CheckVer(GetGameDir());
Ver = Ver.substr(0, Ver.find('.', Ver.find('.') + 1)); Ver = Ver.substr(0, Ver.find('.', Ver.find('.') + 1));
Path += Utils::ToWString(Ver) + L"\\"; (Path /= Utils::ToWString(Ver)) /= L"\\";
return Path; return Path;
} }
#elif defined(__linux__) #elif defined(__linux__)

View File

@ -337,7 +337,7 @@ void PreGame(const beammp_fs_string& GamePath) {
beammp_fs_string Target(GetGamePath() + beammp_wide("mods/unpacked/beammp")); beammp_fs_string Target(GetGamePath() + beammp_wide("mods/unpacked/beammp"));
if (fs::is_directory(Target) && !fs::is_directory(Target + "/.git")) { if (fs::is_directory(Target) && !fs::is_directory(Target + beammp_wide("/.git"))) {
fs::remove_all(Target); fs::remove_all(Target);
} }
} }