mirror of
https://github.com/HarbourMasters/Shipwright
synced 2026-06-17 23:41:06 -04:00
Redone fast file select (#1854)
* Redone fast file select * Update soh/src/overlays/gamestates/ovl_title/z_title.c * Prevent loading incompatible saves * Dont change cvar on incompatible file
This commit is contained in:
@@ -685,14 +685,13 @@ void SaveManager::LoadFile(int fileNum) {
|
||||
}
|
||||
|
||||
bool SaveManager::SaveFile_Exist(int fileNum) {
|
||||
|
||||
try {
|
||||
std::filesystem::exists(GetFileName(fileNum));
|
||||
printf("File[%d] - exist \n",fileNum);
|
||||
return true;
|
||||
bool exists = std::filesystem::exists(GetFileName(fileNum));
|
||||
SPDLOG_INFO("File[{}] - {}", fileNum, exists ? "exists" : "does not exist" );
|
||||
return exists;
|
||||
}
|
||||
catch(std::filesystem::filesystem_error const& ex) {
|
||||
printf("File[%d] - do not exist \n",fileNum);
|
||||
SPDLOG_ERROR("Filesystem error");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user