If you have tried to use savedatafiler on Gateway's red-card, you will see card1 type ROM shown like "CTR broken data" in SDF lower screen.
this prevents we convert our exists gamesave from gw rom to cia games.
by looking into real game exefs (MH4G) I noticed there two call to load savedata:
I guess Gateway is just breaked MEDIA_TYPE_CTRCARD codepath, and hooked SDMC one with non standard 6.x key, in other words, they dropped spi flash support in hardware level that savedatafiler expect.
sadly ctrulib missed savedata support, If we can rip savedata related functions from the new rom, and built 3ds format homebrew rom with same titleID/saveID, I think savedata will mounted after our homebrew start so we can export it now.
any suggestions?
this prevents we convert our exists gamesave from gw rom to cia games.
by looking into real game exefs (MH4G) I noticed there two call to load savedata:
Code:
nn::Result nn::fs::MountSaveData(const char *archiveName, bit32 uniqueId, bit8 variation)
{
nn::Result result= nn::fs::MountOtherUserSaveData(archiveName, MEDIA_TYPE_CTRCARD, uniqueId, variation);
if ( (result.value & 0x80000000 & 0x80000000) != 0 )
{
result= nn::fs::MountOtherUserSaveData(archiveName, MEDIA_TYPE_SDMC, uniqueId, variation);
if ( (result.value & 0x80000000 & 0x80000000) != 0 )
result.value = 0xC8804464;
}
return result;
}
I guess Gateway is just breaked MEDIA_TYPE_CTRCARD codepath, and hooked SDMC one with non standard 6.x key, in other words, they dropped spi flash support in hardware level that savedatafiler expect.
sadly ctrulib missed savedata support, If we can rip savedata related functions from the new rom, and built 3ds format homebrew rom with same titleID/saveID, I think savedata will mounted after our homebrew start so we can export it now.
any suggestions?