mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-12-24 09:20:58 +01:00
Archives: Make SYSTEM_ID and SDCARD_ID strings
This commit is contained in:
parent
71a063f45c
commit
90dffe3fc1
6 changed files with 11 additions and 9 deletions
|
@ -27,9 +27,10 @@ static std::string GetExtSaveDataPath(const std::string& mount_point, const Path
|
||||||
|
|
||||||
static std::string GetExtDataContainerPath(const std::string& mount_point, bool shared) {
|
static std::string GetExtDataContainerPath(const std::string& mount_point, bool shared) {
|
||||||
if (shared)
|
if (shared)
|
||||||
return Common::StringFromFormat("%sdata/%32x/extdata/", mount_point.c_str(), ID0);
|
return Common::StringFromFormat("%sdata/%s/extdata/", mount_point.c_str(), SYSTEM_ID.c_str());
|
||||||
|
|
||||||
return Common::StringFromFormat("%sNintendo 3DS/%32x/%32x/extdata/", mount_point.c_str(), ID0, ID1);
|
return Common::StringFromFormat("%sNintendo 3DS/%s/%s/extdata/", mount_point.c_str(),
|
||||||
|
SYSTEM_ID.c_str(), SDCARD_ID.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
Archive_ExtSaveData::Archive_ExtSaveData(const std::string& mount_location, bool shared)
|
Archive_ExtSaveData::Archive_ExtSaveData(const std::string& mount_location, bool shared)
|
||||||
|
|
|
@ -18,7 +18,8 @@
|
||||||
namespace FileSys {
|
namespace FileSys {
|
||||||
|
|
||||||
static std::string GetSaveDataContainerPath(const std::string& mount_point) {
|
static std::string GetSaveDataContainerPath(const std::string& mount_point) {
|
||||||
return Common::StringFromFormat("%sNintendo 3DS/%32x/%32x/title/", mount_point.c_str(), ID0, ID1);
|
return Common::StringFromFormat("%sNintendo 3DS/%s/%s/title/", mount_point.c_str(),
|
||||||
|
SYSTEM_ID.c_str(), SDCARD_ID.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
static std::string GetSaveDataPath(const std::string& mount_point, u64 program_id) {
|
static std::string GetSaveDataPath(const std::string& mount_point, u64 program_id) {
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
namespace FileSys {
|
namespace FileSys {
|
||||||
|
|
||||||
static std::string GetSaveDataCheckContainerPath(const std::string& mount_point) {
|
static std::string GetSaveDataCheckContainerPath(const std::string& mount_point) {
|
||||||
return Common::StringFromFormat("%stitle/", mount_point.c_str(), ID0);
|
return Common::StringFromFormat("%s%s/title", mount_point.c_str(), SYSTEM_ID.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
static std::string GetSaveDataCheckPath(const std::string& mount_point, u32 high, u32 low) {
|
static std::string GetSaveDataCheckPath(const std::string& mount_point, u32 high, u32 low) {
|
||||||
|
|
|
@ -24,7 +24,7 @@ static std::string GetSystemSaveDataPath(const std::string& mount_point, u64 sav
|
||||||
}
|
}
|
||||||
|
|
||||||
static std::string GetSystemSaveDataContainerPath(const std::string& mount_point) {
|
static std::string GetSystemSaveDataContainerPath(const std::string& mount_point) {
|
||||||
return Common::StringFromFormat("%sdata/%32x/sysdata/", mount_point.c_str(), ID0);
|
return Common::StringFromFormat("%sdata/%s/sysdata/", mount_point.c_str(), SYSTEM_ID.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
Archive_SystemSaveData::Archive_SystemSaveData(const std::string& mount_point, u64 save_id)
|
Archive_SystemSaveData::Archive_SystemSaveData(const std::string& mount_point, u64 save_id)
|
||||||
|
|
|
@ -36,8 +36,8 @@ namespace std {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
const u32 SYSTEM_ID = 0;
|
const std::string SYSTEM_ID = "00000000000000000000000000000000";
|
||||||
const u32 SDCARD_ID = 0;
|
const std::string SDCARD_ID = "00000000000000000000000000000000";
|
||||||
|
|
||||||
namespace Service {
|
namespace Service {
|
||||||
namespace FS {
|
namespace FS {
|
||||||
|
|
|
@ -11,9 +11,9 @@
|
||||||
#include "core/hle/result.h"
|
#include "core/hle/result.h"
|
||||||
|
|
||||||
/// The unique system identifier hash, also known as ID0
|
/// The unique system identifier hash, also known as ID0
|
||||||
extern const u32 SYSTEM_ID;
|
extern const std::string SYSTEM_ID;
|
||||||
/// The scrambled SD card CID, also known as ID1
|
/// The scrambled SD card CID, also known as ID1
|
||||||
extern const u32 SDCARD_ID;
|
extern const std::string SDCARD_ID;
|
||||||
|
|
||||||
namespace Service {
|
namespace Service {
|
||||||
namespace FS {
|
namespace FS {
|
||||||
|
|
Loading…
Reference in a new issue