Look for a mod's Atmosphere folders under this game's title id, 0400486024DEC000.

The runtime, the setup's cheat and ExeFS patch tools and the old installer named them after another game's title id, so
a mod laid out as atmosphere/contents/<title id>/romfs (or contents/<title id>, <title id>) was listed as empty.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-08 08:47:59 -05:00
parent 3aa8ff56a2
commit 1f4839d4a5
5 changed files with 13 additions and 11 deletions

View File

@@ -815,8 +815,10 @@ EMITTED = re.compile(r'^emitted (\d+)/(\d+) chunks')
DISCOVERED = re.compile(r'^(\w+): \d+ functions \(.*discovery')
CHEAT_PLACES = ('cheats', 'atmosphere/contents/0100F2C0115B6000/cheats', 'contents/0100F2C0115B6000/cheats',
'0100F2C0115B6000/cheats')
MOD_TITLE = '0400486024DEC000' # the game's title id, which names a mod's Atmosphere folders (tools/cheats.py TITLE)
CHEAT_PLACES = ('cheats', f'atmosphere/contents/{MOD_TITLE}/cheats', f'contents/{MOD_TITLE}/cheats',
f'{MOD_TITLE}/cheats')
def cheat_files(ctx):
@@ -831,8 +833,8 @@ def cheat_files(ctx):
for f in ((mod / where).glob('*.txt') if (mod / where).is_dir() else ()))
EXEFS_PLACES = ('exefs', 'atmosphere/contents/0100F2C0115B6000/exefs', 'contents/0100F2C0115B6000/exefs',
'0100F2C0115B6000/exefs')
EXEFS_PLACES = ('exefs', f'atmosphere/contents/{MOD_TITLE}/exefs', f'contents/{MOD_TITLE}/exefs',
f'{MOD_TITLE}/exefs')
def exefs_files(ctx):

View File

@@ -27,7 +27,7 @@
#include "mods.h"
#include "platform/platform.h"
#define TITLE "0100F2C0115B6000"
#define TITLE "0400486024DEC000" // the game's title id, which names a mod's Atmosphere folders
#define MAX_MODS 512
static ModInfo *mods;

View File

@@ -60,8 +60,8 @@ int probe_mods(void) {
remove_tree(root);
plat_file_mkdir_p(root);
static const char *const files[] = {
"A/romfs/x.bin", "B/atmosphere/contents/0100F2C0115B6000/romfs/x.bin",
"C/contents/0100F2C0115B6000/romfs/y.bin", "D/exefs/main.pchtxt", "E/exefs/subsdk9", "F/romfs/",
"A/romfs/x.bin", "B/atmosphere/contents/0400486024DEC000/romfs/x.bin",
"C/contents/0400486024DEC000/romfs/y.bin", "D/exefs/main.pchtxt", "E/exefs/subsdk9", "F/romfs/",
"G/romfs/z.bin", "G/exefs/1234.ips", "Ultra \xD0\x96/romfs/u.bin",
"H/romfs/h.bin", "H/exefs/subsdk9", "I/romfs/i.bin", "I/exefs/main", "J/cheats/0123456789ABCDEF.txt",
"K/romfslite/k.bin", "L/romfs/l.bin", "L/cheats/0123456789ABCDEF.txt", "L/exefs/main.npdm",
@@ -90,8 +90,8 @@ int probe_mods(void) {
*lm = mods_at(11), *mm = mods_at(12), *u = mods_at(13);
CHECK(hm->kind == (MOD_ROMFS | MOD_SUBSDK) && hm->problem == MOD_PLUGIN, "RomFS + subsdk plugin: unusable");
CHECK(im->kind == (MOD_ROMFS | MOD_SUBSDK) && im->problem == MOD_PLUGIN, "RomFS + replaced exefs/main");
CHECK(ends_with(b->romfs, "B/atmosphere/contents/0100F2C0115B6000/romfs"), "Atmosphere RomFS root");
CHECK(ends_with(c->romfs, "C/contents/0100F2C0115B6000/romfs"), "contents RomFS root");
CHECK(ends_with(b->romfs, "B/atmosphere/contents/0400486024DEC000/romfs"), "Atmosphere RomFS root");
CHECK(ends_with(c->romfs, "C/contents/0400486024DEC000/romfs"), "contents RomFS root");
CHECK(ends_with(a->romfs, "A/romfs") && a->kind == MOD_ROMFS && a->problem == MOD_OK, "plain RomFS mod");
CHECK(!c->enabled && a->enabled && b->enabled && g->enabled && u->enabled, "mods_disabled switches C off");
CHECK(d->kind == MOD_EXEFS && d->problem == MOD_EXEFS_OTHER && d->other_version == 1,

View File

@@ -277,7 +277,7 @@ class LiftKeyTest(unittest.TestCase):
self.add_cheats('277178B7DBA1B6D4.txt', '[b]')
edited = self.key()
self.assertNotEqual(edited, added)
self.add_cheats('277178B7DBA1B6D4.txt', '[c]', mod='Other', where='atmosphere/contents/0100F2C0115B6000/cheats')
self.add_cheats('277178B7DBA1B6D4.txt', '[c]', mod='Other', where='atmosphere/contents/0400486024DEC000/cheats')
self.assertNotEqual(self.key(), edited)
def test_exefs_patch_files_change_the_key(self):

View File

@@ -90,7 +90,7 @@ def parse(text, mod):
return out
TITLE = '0100F2C0115B6000'
TITLE = '0400486024DEC000' # the game's title id: a mod's Atmosphere folders are named after it
def cheat_files(mods, bid):