WiiSaveBanner: fall back to $userdir/Load/WiiBanners

Unlike custom banners which work as an override, this mechanism works as
a fallback. The use case is if you have games you don't really play but
want to keep around for testing purposes without filling up your NAND
with lots of saves. For ease of use, the directory structure is the same
but only title/$title_hi/$title_lo/data/banner.bin files are
relevant.
This commit is contained in:
Tillmann Karras
2025-06-15 11:13:18 +01:00
parent a5e85caf0a
commit fe6fd2279c
7 changed files with 30 additions and 9 deletions

View File

@ -19,7 +19,19 @@ namespace Common
{
std::string RootUserPath(FromWhichRoot from)
{
int idx = from == FromWhichRoot::Configured ? D_WIIROOT_IDX : D_SESSION_WIIROOT_IDX;
int idx{};
switch (from)
{
case FromWhichRoot::Configured:
idx = D_WIIROOT_IDX;
break;
case FromWhichRoot::Session:
idx = D_SESSION_WIIROOT_IDX;
break;
case FromWhichRoot::Banners:
idx = D_BANNERS_WIIROOT_IDX;
break;
}
std::string dir = File::GetUserPath(idx);
dir.pop_back(); // remove trailing path separator
return dir;