@gaialabs/iog-baserom 0.2.4 → 0.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/baserom/patches/APUWaitFixes.patch.asm +5 -5
- package/baserom/patches/Cop51Patch.patch.asm +1 -1
- package/baserom/patches/EquippedIcon.patch.asm +24 -2
- package/baserom/patches/InventoryManagement.patch.asm +1 -1
- package/baserom/patches/MusicTransitions.patch.asm +1 -1
- package/baserom/patches/NewGamePlus.patch.asm +19 -19
- package/baserom/patches/Utils.patch.asm +14 -3
- package/dist/index.cjs +1930 -15859
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +1932 -15861
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -2
- package/baserom/widescreen.bso +0 -4
- /package/baserom/asm/{table_179000.asm → spriteset_aura.asm} +0 -0
- /package/baserom/asm/{table_178000.asm → spriteset_dark_friar.asm} +0 -0
- /package/baserom/asm/{table_17D000.asm → spriteset_will_projectile.asm} +0 -0
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":["mnemonics","overrides","blocks","copdef","files","groups","strings","structs","config","fileTypes","mnemonicsJP","overridesJP","rewritesJP","blocksJP","copdefJP","filesJP","groupsJP","labelsJP","stringsJP","structsJP","transformsJP","configJP","fileTypesJP","namesJP"],"sources":["../db-us/config.json","../db-us/blocks.json","../db-us/copdef.json","../db-us/files.json","../db-us/groups.json","../db-us/labels.json","../db-us/mnemonics.json","../db-us/overrides.json","../db-us/rewrites.json","../db-us/stringTypes.json","../db-us/structs.json","../db-us/transforms.json","../db-us/fileTypes.json","../db-us/names.json","../db-us/types.json","../db-jp/config.json","../db-jp/blocks.json","../db-jp/files.json","../db-jp/groups.json","../db-jp/labels.json","../db-jp/overrides.json","../db-jp/rewrites.json","../db-jp/stringTypes.json","../db-jp/structs.json","../db-jp/transforms.json","../db-jp/names.json","../src/index.ts"],"sourcesContent":["","","","","","","","","","","","","","","","","","","","","","","","","","","import { fileURLToPath } from 'url';\r\nimport { dirname, join, resolve } from 'path';\r\nimport { existsSync, readdirSync, readFileSync } from 'fs';\r\nimport { DbBlock, DbFile, DbGroup, DbStringType, DbStruct, CopDef, DbFileType, AsmBlock, saveFileAsText, RomProcessingConstants, crc32_buffer } from '@gaialabs/core';\r\nimport { DbRootUtils } from '@gaialabs/core';\r\nimport type { DbAddressingMode, DbConfig, DbGameRomModule } from '@gaialabs/core';\r\nimport { snes } from '@gaialabs/core';\r\n\r\nconst __pkgRoot = join(dirname(fileURLToPath(import.meta.url)), '..');\r\n\r\nimport config from '../db-us/config.json' with { type: 'json' };\r\nimport blocks from '../db-us/blocks.json' with { type: 'json' };\r\nimport copdef from '../db-us/copdef.json' with { type: 'json' };\r\nimport files from '../db-us/files.json' with { type: 'json' };\r\nimport groups from '../db-us/groups.json' with { type: 'json' };\r\nimport labels from '../db-us/labels.json' with { type: 'json' };\r\nimport mnemonics from '../db-us/mnemonics.json' with { type: 'json' };\r\nimport overrides from '../db-us/overrides.json' with { type: 'json' };\r\nimport rewrites from '../db-us/rewrites.json' with { type: 'json' };\r\nimport strings from '../db-us/stringTypes.json' with { type: 'json' };\r\nimport structs from '../db-us/structs.json' with { type: 'json' };\r\nimport transforms from '../db-us/transforms.json' with { type: 'json' };\r\nimport fileTypes from '../db-us/fileTypes.json' with { type: 'json' };\r\nimport names from '../db-us/names.json' with { type: 'json' };\r\nimport types from '../db-us/types.json' with { type: 'json' };\r\n\r\nfunction loadNotesDir(subdir: string): Record<string, string> {\r\n const dir = join(__pkgRoot, 'notes', subdir);\r\n if (!existsSync(dir)) return {};\r\n\r\n const merged: Record<string, string> = {};\r\n for (const file of readdirSync(dir)) {\r\n if (!file.endsWith('.json')) continue;\r\n const data = JSON.parse(readFileSync(join(dir, file), 'utf-8'));\r\n Object.assign(merged, data);\r\n }\r\n return merged;\r\n}\r\n\r\nfunction loadLocalNotes(): { comments: Record<string, string>; blockNotes: Record<string, string>; partNotes: Record<string, string> } {\r\n const notesDir = join(__pkgRoot, 'notes');\r\n if (!existsSync(notesDir)) {\r\n return { comments: {}, blockNotes: {}, partNotes: {} };\r\n }\r\n return {\r\n comments: loadNotesDir('comments'),\r\n blockNotes: loadNotesDir('blockNotes'),\r\n partNotes: loadNotesDir('partNotes')\r\n };\r\n}\r\n\r\nimport configJP from '../db-jp/config.json' with { type: 'json' };\r\nimport blocksJP from '../db-jp/blocks.json' with { type: 'json' };\r\nimport copdefJP from '../db-us/copdef.json' with { type: 'json' };\r\nimport filesJP from '../db-jp/files.json' with { type: 'json' };\r\nimport groupsJP from '../db-jp/groups.json' with { type: 'json' };\r\nimport labelsJP from '../db-jp/labels.json' with { type: 'json' };\r\nimport mnemonicsJP from '../db-us/mnemonics.json' with { type: 'json' };\r\nimport overridesJP from '../db-jp/overrides.json' with { type: 'json' };\r\nimport rewritesJP from '../db-jp/rewrites.json' with { type: 'json' };\r\nimport stringsJP from '../db-jp/stringTypes.json' with { type: 'json' };\r\nimport structsJP from '../db-jp/structs.json' with { type: 'json' };\r\nimport transformsJP from '../db-jp/transforms.json' with { type: 'json' };\r\nimport fileTypesJP from '../db-us/fileTypes.json' with { type: 'json' };\r\nimport namesJP from '../db-jp/names.json' with { type: 'json' };\r\n\r\nconst localNotes = loadLocalNotes();\r\n\r\nexport const db : DbGameRomModule = {\r\n mnemonics: { ...snes.vectors, ...mnemonics },\r\n overrides: overrides as unknown as Record<string, Record<string, number>>,\r\n rewrites,\r\n blocks: blocks as unknown as Record<string, Record<string, Partial<DbBlock>>>,\r\n copdef: copdef as unknown as Record<string, Partial<CopDef>>,\r\n files: files as unknown as Record<string, Record<string, Record<string, Partial<DbFile>>>>,\r\n groups: groups as unknown as Record<string, Partial<DbGroup>>,\r\n labels, //: labels as unknown as Record<string, string>,\r\n strings: strings as unknown as Record<string, Partial<DbStringType>>,\r\n structs: structs as unknown as Record<string, DbStruct>,\r\n transforms,\r\n config: config as unknown as DbConfig,\r\n fileTypes: fileTypes as unknown as Record<string, Partial<DbFileType>>,\r\n addrModes: snes.addressingModes as unknown as Record<string, Partial<DbAddressingMode>>,\r\n headers: snes.headers,\r\n names,\r\n types,\r\n comments: localNotes.comments,\r\n blockNotes: localNotes.blockNotes,\r\n partNotes: localNotes.partNotes\r\n};\r\n\r\nexport const jp : DbGameRomModule = {\r\n mnemonics: { ...snes.vectors, ...mnemonicsJP },\r\n overrides: overridesJP as unknown as Record<string, Record<string, number>>,\r\n rewrites: rewritesJP,\r\n blocks: blocksJP as unknown as Record<string, Record<string, Partial<DbBlock>>>,\r\n copdef: copdefJP as unknown as Record<string, Partial<CopDef>>,\r\n files: filesJP as unknown as Record<string, Record<string, Record<string, Partial<DbFile>>>>,\r\n groups: groupsJP as unknown as Record<string, Partial<DbGroup>>,\r\n labels: labelsJP, // as unknown as Record<number, string>,\r\n strings: stringsJP as unknown as Record<string, Partial<DbStringType>>,\r\n structs: { ...structs, ...structsJP } as unknown as Record<string, DbStruct>,\r\n transforms: transformsJP,\r\n config: configJP as unknown as DbConfig,\r\n fileTypes: fileTypesJP as unknown as Record<string, Partial<DbFileType>>,\r\n addrModes: snes.addressingModes as unknown as Record<string, Partial<DbAddressingMode>>,\r\n headers: snes.headers,\r\n names: namesJP\r\n};\r\n\r\nexport async function extract(romPath: string, outPath: string, options?: string[]) {\r\n if (!romPath) romPath = process.env.ROM_PATH;\r\n if(!outPath) outPath = './extracted';\r\n\r\n var dbRoot = DbRootUtils.fromGameModule(db);\r\n\r\n if(options?.includes('linetracking')) dbRoot.config.emitLineTracking = true;\r\n\r\n await DbRootUtils.extractAllContent(dbRoot, romPath, outPath);\r\n}\r\n\r\nexport async function extractJP(romPath: string, outPath: string) {\r\n if (!romPath) romPath = process.env.ROM_PATH_JP;\r\n if(!outPath) outPath = './extracted-jp';\r\n\r\n var dbRoot = DbRootUtils.fromGameModule(jp);\r\n\r\n await DbRootUtils.extractAllContent(dbRoot, romPath, outPath);\r\n}\r\n\r\nexport async function rebuild(inPath: string, outPath: string, baseRomPath: string, modulePaths?: string[], options?: string[]) {\r\n if(!inPath) inPath = './extracted';\r\n if(!outPath) outPath = `./rebuilt/${process.env.ROM_NAME ?? 'Illusion of Gaia - Rebuilt'}.smc`;\r\n if(!baseRomPath) baseRomPath = join(__pkgRoot, 'baserom');\r\n \r\n var dbRoot = DbRootUtils.fromGameModule(db);\r\n\r\n const outData = await DbRootUtils.rebuildAllContent(dbRoot, [inPath, baseRomPath, ...(modulePaths || [])], outPath);\r\n \r\n if(options?.includes('artifacts')) {\r\n console.log('Generating artifacts...');\r\n const artifactPath = './artifacts';\r\n let totalSize = 0;\r\n\r\n const fileLayoutArtifact = outData.files.filter((file) => file.size > 0).sort((a, b) => a.location - b.location).map((file) => {\r\n totalSize += file.size;\r\n return ` \"${file.location.toString(16).toUpperCase().padStart(6, '0')}\" : \"${file.name}\"`;\r\n });\r\n\r\n const fileLayoutArtifactText = `{${RomProcessingConstants.NEWLINE}${fileLayoutArtifact.join(',' + RomProcessingConstants.NEWLINE)}${RomProcessingConstants.NEWLINE}}`;\r\n await saveFileAsText(join(artifactPath, 'file-layout.json'), fileLayoutArtifactText);\r\n\r\n const masterArtifact = Object.entries(outData.masterLookup)\r\n .filter((entry) => !entry[0].match(/[!+-]$/))\r\n .sort((a, b) => a[1].location - b[1].location)\r\n .map((entry) => {\r\n return ` \"${entry[0]}\": \"${entry[1].location.toString(16).toUpperCase().padStart(6, '0')}\"`;\r\n });\r\n\r\n const masterArtifactText = `{${RomProcessingConstants.NEWLINE}${masterArtifact.join(',' + RomProcessingConstants.NEWLINE)}${RomProcessingConstants.NEWLINE}}`;\r\n await saveFileAsText(join(artifactPath, 'master-lookup.json'), masterArtifactText);\r\n\r\n const crc = crc32_buffer(outData.romData);\r\n const crcText = JSON.stringify({ checksum: outData.header.checksum, crc, totalSize }, null, 2);\r\n await saveFileAsText(join(artifactPath, 'crc.json'), crcText);\r\n }\r\n}\r\n\r\nexport async function rebuildJp(inPath: string, outPath: string, baseRomPath: string, modulePaths?: string[]) {\r\n if(!inPath) inPath = './extracted-jp';\r\n if(!outPath) outPath = `./rebuilt-jp/${process.env.ROM_NAME_JP ?? 'Gaia Gensouki - Rebuilt'}.smc`;\r\n if(!baseRomPath) baseRomPath = join(__pkgRoot, 'baserom-jp');\r\n \r\n var dbRoot = DbRootUtils.fromGameModule(jp);\r\n\r\n await DbRootUtils.rebuildAllContent(dbRoot, [inPath, baseRomPath, ...(modulePaths || [])], outPath);\r\n}\r\n\r\n// CLI handler - only execute when run directly (not when imported as a module)\r\n// Check if this module is being run directly\r\nconst isMainModule = resolve(process.argv[1] || '') === fileURLToPath(import.meta.url);\r\n\r\nif (isMainModule) {\r\n const command = process.argv[2];\r\n const args = process.argv.slice(3);\r\n\r\n const flags = [];\r\n for(let index = 0; index < args.length; index++) {\r\n const arg = args[index];\r\n if(arg.startsWith('--')) {\r\n flags.push(arg.slice(2).toLowerCase());\r\n args.splice(index, 1);\r\n index--;\r\n }\r\n }\r\n\r\n // const options = flags.reduce((acc, flag) => {\r\n // acc[flag] = true;\r\n // return acc;\r\n // }, {});\r\n\r\n (async () => {\r\n try {\r\n switch (command) {\r\n case 'extract':\r\n console.log('Starting ROM extraction...');\r\n console.log('ROM Path:', args[0]);\r\n console.log('Output Path:', args[1] || '../extracted');\r\n await extract(args[0], args[1], flags);\r\n console.log('ROM extraction completed successfully!');\r\n break;\r\n case 'extract-jp':\r\n console.log('Starting ROM extraction...');\r\n console.log('ROM Path:', args[0]);\r\n console.log('Output Path:', args[1] || '../extracted-jp');\r\n await extractJP(args[0], args[1]);\r\n console.log('ROM extraction completed successfully!');\r\n break;\r\n case 'rebuild':\r\n console.log('Starting ROM rebuild...');\r\n await rebuild(args[0], args[1], args[2], undefined, flags);\r\n console.log('ROM rebuild completed successfully!');\r\n break;\r\n case 'rebuild-jp':\r\n console.log('Starting JP ROM rebuild...');\r\n await rebuild(args[0], args[1], args[2]);\r\n console.log('ROM rebuild completed successfully!');\r\n break;\r\n default:\r\n console.error('Unknown command:', command);\r\n console.log('Available commands: extractRom, rebuildRom');\r\n process.exit(1);\r\n }\r\n } catch (error) {\r\n console.error('Error:', error);\r\n process.exit(1);\r\n }\r\n })();\r\n}\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AI,IAAI,QAAQ,GAAG,QAAQ,KAAK,QAAQ,SAAS;EAC7C,MAAM,MAAM,KAAK;EACjB,IAAG,IAAI,WAAW,IAAI,GAAG;GACrB,MAAM,KAAK,IAAI,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC;GACrC,KAAK,OAAO,OAAO,CAAC;GACpB;EACJ;CACJ;CAOA,CAAC,YAAY;EACT,IAAI;GACA,QAAQ,SAAR;IACI,KAAK;KACD,QAAQ,IAAI,4BAA4B;KACxC,QAAQ,IAAI,aAAa,KAAK,EAAE;KAChC,QAAQ,IAAI,gBAAgB,KAAK,MAAM,cAAc;KACrD,MAAM,QAAQ,KAAK,IAAI,KAAK,IAAI,KAAK;KACrC,QAAQ,IAAI,wCAAwC;KACpD;IACJ,KAAK;KACD,QAAQ,IAAI,4BAA4B;KACxC,QAAQ,IAAI,aAAa,KAAK,EAAE;KAChC,QAAQ,IAAI,gBAAgB,KAAK,MAAM,iBAAiB;KACxD,MAAM,UAAU,KAAK,IAAI,KAAK,EAAE;KAChC,QAAQ,IAAI,wCAAwC;KACpD;IACJ,KAAK;KACD,QAAQ,IAAI,yBAAyB;KACrC,MAAM,QAAQ,KAAK,IAAI,KAAK,IAAI,KAAK,IAAI,QAAW,KAAK;KACzD,QAAQ,IAAI,qCAAqC;KACjD;IACJ,KAAK;KACD,QAAQ,IAAI,4BAA4B;KACxC,MAAM,QAAQ,KAAK,IAAI,KAAK,IAAI,KAAK,EAAE;KACvC,QAAQ,IAAI,qCAAqC;KACjD;IACJ;KACI,QAAQ,MAAM,oBAAoB,OAAO;KACzC,QAAQ,IAAI,4CAA4C;KACxD,QAAQ,KAAK,CAAC;GACtB;EACJ,SAAS,OAAO;GACZ,QAAQ,MAAM,UAAU,KAAK;GAC7B,QAAQ,KAAK,CAAC;EAClB;CACJ,EAAC,CAAE;AACP"}
|
|
1
|
+
{"version":3,"file":"index.mjs","names":["mnemonics","overrides","blocks","copdef","files","groups","strings","structs","config","fileTypes","mnemonicsJP","overridesJP","rewritesJP","blocksJP","copdefJP","filesJP","groupsJP","labelsJP","stringsJP","structsJP","transformsJP","configJP","fileTypesJP","namesJP"],"sources":["../src/ingest.ts","../db-us/config.json","../db-us/blocks.json","../db-us/copdef.json","../db-us/files.json","../db-us/groups.json","../db-us/labels.json","../db-us/mnemonics.json","../db-us/overrides.json","../db-us/rewrites.json","../db-us/stringTypes.json","../db-us/structs.json","../db-us/transforms.json","../db-us/fileTypes.json","../db-us/names.json","../db-us/types.json","../db-jp/config.json","../db-jp/blocks.json","../db-jp/files.json","../db-jp/groups.json","../db-jp/labels.json","../db-jp/overrides.json","../db-jp/rewrites.json","../db-jp/stringTypes.json","../db-jp/structs.json","../db-jp/transforms.json","../db-jp/names.json","../src/index.ts"],"sourcesContent":["/**\r\n * Notes Ingestion Module\r\n *\r\n * Parses extracted .asm files and ingests block notes, part notes, and inline\r\n * comments into the notes/ JSON directory structure. This eliminates the need\r\n * for agents to manually edit JSON files — the most error-prone step in the\r\n * documentation workflow.\r\n *\r\n * Workflow:\r\n * 1. Run `npm run extract:lt` to produce address-tagged .asm output\r\n * 2. Edit the .asm files: add/update/remove block notes, part notes, and\r\n * inline comments (keeping {address} tags for inline comments)\r\n * 3. Run `npm run ingest` to parse the edits and write to notes/ JSON\r\n * 4. Run `npm run extract` to verify the final output\r\n *\r\n * Inline comment format in extract:lt output:\r\n * With existing comment: ` LDA $00B2 ; {39414} existing comment`\r\n * Without comment: ` PLA ; {39419}`\r\n * Agent adds comment: ` PLA ; {39419} new comment text`\r\n * Agent removes comment: ` LDA $00B2 ; {39414}` (delete text after tag)\r\n *\r\n * The ingest script supports additions, updates, AND deletions:\r\n * - Additions: new annotations found in the .asm file are added to JSON\r\n * - Updates: changed annotations overwrite the existing JSON entry\r\n * - Deletions: annotations present in JSON but absent from the .asm file\r\n * are removed (scoped to the processed file's labels/addresses)\r\n */\r\n\r\nimport { readFileSync, writeFileSync, existsSync, mkdirSync, readdirSync } from 'fs';\r\nimport { join, basename, extname, dirname, relative } from 'path';\r\n\r\nexport interface IngestOptions {\r\n dryRun?: boolean;\r\n verbose?: boolean;\r\n}\r\n\r\nexport interface IngestStats {\r\n filesProcessed: number;\r\n filesSkipped: number;\r\n blockNotesFound: number;\r\n blockNotesNew: number;\r\n blockNotesUpdated: number;\r\n blockNotesDeleted: number;\r\n partNotesFound: number;\r\n partNotesNew: number;\r\n partNotesUpdated: number;\r\n partNotesDeleted: number;\r\n commentsFound: number;\r\n commentsNew: number;\r\n commentsUpdated: number;\r\n commentsDeleted: number;\r\n hasLineTracking: boolean;\r\n}\r\n\r\ninterface ParsedAnnotations {\r\n blockNote?: { name: string; text: string };\r\n partNotes: Map<string, string>;\r\n comments: Map<number, string>;\r\n // Deletion detection\r\n fileName: string;\r\n hasStructure: boolean;\r\n allLabels: Set<string>;\r\n uncommentedAddresses: Set<number>;\r\n bank: number | null;\r\n hasLineTracking: boolean;\r\n}\r\n\r\n/**\r\n * Build a name → bank lookup from names.json for bank detection fallback.\r\n */\r\nfunction loadNamesBankLookup(namesPath: string): Map<string, number> {\r\n const lookup = new Map<string, number>();\r\n if (!existsSync(namesPath)) return lookup;\r\n try {\r\n const names: Record<string, string> = JSON.parse(readFileSync(namesPath, 'utf-8'));\r\n for (const [addr, name] of Object.entries(names)) {\r\n const address = parseInt(addr, 10);\r\n if (!isNaN(address)) {\r\n lookup.set(name, Math.floor(address / 65536));\r\n }\r\n }\r\n } catch { /* ignore parse errors */ }\r\n return lookup;\r\n}\r\n\r\n/**\r\n * Detect the ROM bank for a file using multiple strategies.\r\n */\r\nfunction detectBank(lines: string[], fileName: string, namesLookup: Map<string, number>): number | null {\r\n // Strategy 1: ?BANK directive\r\n for (const line of lines) {\r\n const match = line.match(/^\\?BANK\\s+([0-9A-Fa-f]+)/);\r\n if (match) return parseInt(match[1], 16);\r\n }\r\n\r\n // Strategy 2: code_XXXXXX or loc_XXXXXX labels (hex address in label name)\r\n for (const line of lines) {\r\n const match = line.match(/\\b(?:code|loc)_([0-9A-Fa-f]{6})\\b/);\r\n if (match) {\r\n const addr = parseInt(match[1], 16);\r\n return Math.floor(addr / 0x10000);\r\n }\r\n }\r\n\r\n // Strategy 3: {address} tags from extract:lt\r\n for (const line of lines) {\r\n const match = line.match(/;\\s*\\{(\\d+)\\}/);\r\n if (match) {\r\n return Math.floor(parseInt(match[1], 10) / 65536);\r\n }\r\n }\r\n\r\n // Strategy 4: File name or top-level label in names.json\r\n if (namesLookup.has(fileName)) {\r\n return namesLookup.get(fileName)!;\r\n }\r\n\r\n // Strategy 5: First top-level label found in names.json\r\n for (const line of lines) {\r\n const match = line.match(/^(\\w+)\\s+[\\[{]/);\r\n if (match && namesLookup.has(match[1])) {\r\n return namesLookup.get(match[1])!;\r\n }\r\n }\r\n\r\n return null;\r\n}\r\n\r\n/**\r\n * Extract the block note from the top of a file.\r\n * Block notes are ; -prefixed lines before the first ----- separator.\r\n */\r\nfunction parseBlockNote(lines: string[]): { text: string; endIndex: number } | null {\r\n const noteLines: string[] = [];\r\n let endIndex = -1;\r\n\r\n for (let i = 0; i < lines.length; i++) {\r\n const line = lines[i];\r\n if (line.startsWith('-----')) {\r\n endIndex = i;\r\n break;\r\n }\r\n if (line.startsWith('; ')) {\r\n noteLines.push(line.slice(2));\r\n } else if (line === ';') {\r\n noteLines.push('');\r\n }\r\n }\r\n\r\n if (noteLines.length === 0 || endIndex < 0) return null;\r\n\r\n // Trim trailing empty lines\r\n while (noteLines.length > 0 && noteLines[noteLines.length - 1] === '') {\r\n noteLines.pop();\r\n }\r\n\r\n if (noteLines.length === 0) return null;\r\n\r\n return { text: noteLines.join('\\n'), endIndex };\r\n}\r\n\r\n/**\r\n * Parse a single .asm file for block notes, part notes, and inline comments.\r\n * Also tracks labels without notes and addresses without comments for\r\n * deletion detection.\r\n */\r\nfunction parseFile(filePath: string, namesLookup: Map<string, number>): ParsedAnnotations {\r\n const content = readFileSync(filePath, 'utf-8');\r\n const lines = content.split(/\\r?\\n/);\r\n const fileName = basename(filePath, extname(filePath));\r\n\r\n const result: ParsedAnnotations = {\r\n partNotes: new Map(),\r\n comments: new Map(),\r\n fileName,\r\n hasStructure: false,\r\n allLabels: new Set(),\r\n uncommentedAddresses: new Set(),\r\n bank: null,\r\n hasLineTracking: false,\r\n };\r\n\r\n // Detect structure (has ----- separators)\r\n result.hasStructure = lines.some(l => l.startsWith('-----'));\r\n\r\n // Detect bank\r\n result.bank = detectBank(lines, fileName, namesLookup);\r\n\r\n // Parse block note (top of file before first -----)\r\n const blockNoteResult = parseBlockNote(lines);\r\n if (blockNoteResult) {\r\n result.blockNote = { name: fileName, text: blockNoteResult.text };\r\n }\r\n\r\n // Detect line tracking mode (has ; {address} tags)\r\n result.hasLineTracking = lines.some(l => /;\\s*\\{\\d+\\}/.test(l));\r\n\r\n // Parse part notes, inline comments, and track all labels/addresses\r\n const startIdx = blockNoteResult ? blockNoteResult.endIndex + 1 : 0;\r\n let commentBuffer: string[] = [];\r\n\r\n for (let i = startIdx; i < lines.length; i++) {\r\n const line = lines[i];\r\n\r\n // ----- separator resets comment buffer\r\n if (line.startsWith('-----')) {\r\n commentBuffer = [];\r\n continue;\r\n }\r\n\r\n // Empty line: preserve the comment buffer (notes can span empty ; lines)\r\n if (line.trim() === '') {\r\n continue;\r\n }\r\n\r\n // Non-indented comment line → potential part note content\r\n // Indented comments (4+ spaces) are instruction-level and handled below\r\n if ((line.startsWith('; ') || line === ';') && !line.match(/^\\s{4,}/)) {\r\n const text = line === ';' ? '' : line.slice(2);\r\n commentBuffer.push(text);\r\n continue;\r\n }\r\n\r\n // Top-level label: \"Name {\" or \"Name [\"\r\n const topLevelMatch = line.match(/^(\\w+)\\s+[\\[{]/);\r\n // Internal label: \" Label:\"\r\n const internalMatch = line.match(/^\\s{2}(\\w+):$/);\r\n\r\n const labelName = topLevelMatch?.[1] || internalMatch?.[1];\r\n\r\n if (labelName) {\r\n // Always track the label for deletion detection\r\n result.allLabels.add(labelName);\r\n\r\n if (commentBuffer.length > 0) {\r\n // Trim trailing empty lines from buffer\r\n const trimmed = [...commentBuffer];\r\n while (trimmed.length > 0 && trimmed[trimmed.length - 1] === '') {\r\n trimmed.pop();\r\n }\r\n if (trimmed.length > 0) {\r\n result.partNotes.set(labelName, trimmed.join('\\n'));\r\n }\r\n }\r\n commentBuffer = [];\r\n continue;\r\n }\r\n\r\n // Check for address tags (extract:lt format)\r\n // Match ; {address} with optional trailing text\r\n const addressTagMatch = line.match(/;\\s*\\{(\\d+)\\}\\s*(.*)/);\r\n if (addressTagMatch) {\r\n const address = parseInt(addressTagMatch[1], 10);\r\n const commentText = addressTagMatch[2]?.trim();\r\n if (commentText && commentText.length > 0) {\r\n result.comments.set(address, commentText);\r\n } else {\r\n // Address tag without text → candidate for deletion\r\n result.uncommentedAddresses.add(address);\r\n }\r\n }\r\n\r\n // Non-comment, non-empty, non-separator, non-label line → reset buffer\r\n if (!line.startsWith('; ') && line !== ';') {\r\n commentBuffer = [];\r\n }\r\n }\r\n\r\n return result;\r\n}\r\n\r\n/**\r\n * Generate a bank file name from a bank number: \"bank00.json\", \"bank03.json\", etc.\r\n */\r\nfunction bankFileName(bank: number): string {\r\n return `bank${bank.toString(16).toUpperCase().padStart(2, '0')}.json`;\r\n}\r\n\r\n/**\r\n * Load a JSON file as a string→string record.\r\n */\r\nfunction loadJsonFile(filePath: string): Record<string, string> {\r\n if (!existsSync(filePath)) return {};\r\n try {\r\n return JSON.parse(readFileSync(filePath, 'utf-8'));\r\n } catch {\r\n return {};\r\n }\r\n}\r\n\r\n/**\r\n * Save a string→string record as formatted JSON.\r\n * Numeric keys are sorted numerically; string keys are sorted alphabetically.\r\n * Skips writing if the content is unchanged.\r\n */\r\nfunction saveJsonFile(filePath: string, data: Record<string, string>): boolean {\r\n const dir = dirname(filePath);\r\n if (!existsSync(dir)) mkdirSync(dir, { recursive: true });\r\n\r\n const keys = Object.keys(data);\r\n const allNumeric = keys.every(k => /^\\d+$/.test(k));\r\n\r\n if (allNumeric) {\r\n keys.sort((a, b) => parseInt(a, 10) - parseInt(b, 10));\r\n } else {\r\n keys.sort((a, b) => a.localeCompare(b));\r\n }\r\n\r\n const sorted: Record<string, string> = {};\r\n for (const key of keys) {\r\n sorted[key] = data[key];\r\n }\r\n\r\n const newContent = JSON.stringify(sorted, null, 4) + '\\n';\r\n\r\n // Avoid rewriting unchanged files (prevents spurious git diffs)\r\n if (existsSync(filePath)) {\r\n const existingContent = readFileSync(filePath, 'utf-8');\r\n if (newContent === existingContent) return false;\r\n }\r\n\r\n writeFileSync(filePath, newContent, 'utf-8');\r\n return true;\r\n}\r\n\r\n/**\r\n * Recursively find all .asm files in a directory.\r\n */\r\nfunction findAsmFiles(dir: string): string[] {\r\n const files: string[] = [];\r\n if (!existsSync(dir)) return files;\r\n\r\n const entries = readdirSync(dir, { withFileTypes: true, recursive: true });\r\n for (const entry of entries) {\r\n if (entry.isFile() && entry.name.endsWith('.asm')) {\r\n const parentPath = (entry as any).parentPath || (entry as any).path || dir;\r\n files.push(join(parentPath, entry.name));\r\n }\r\n }\r\n return files;\r\n}\r\n\r\n/** Format a change summary string like \"2 new, 1 updated, 3 deleted\" */\r\nfunction formatChanges(n: number, u: number, d: number): string {\r\n const parts: string[] = [];\r\n if (n > 0) parts.push(`${n} new`);\r\n if (u > 0) parts.push(`${u} updated`);\r\n if (d > 0) parts.push(`${d} deleted`);\r\n return parts.join(', ');\r\n}\r\n\r\n/**\r\n * Main ingestion entry point.\r\n *\r\n * Reads .asm files from extractedDir (or specific targetFiles),\r\n * parses block notes, part notes, and inline comments, then merges\r\n * them into the notes/ JSON directory structure.\r\n *\r\n * Supports additions, updates, AND deletions:\r\n * - Block note deletion: file has structure but no block note → remove from JSON\r\n * - Part note deletion: label appears in file without a note → remove from JSON\r\n * - Comment deletion: address has ; {addr} tag but no text → remove from JSON\r\n *\r\n * Deletions are scoped to processed files only — entries from unprocessed\r\n * files are never touched.\r\n *\r\n * @param projectRoot Root of the baserom project (contains notes/, db-us/, extracted/)\r\n * @param targetFiles Optional list of specific .asm file paths to ingest\r\n * @param options Dry-run and verbosity options\r\n * @returns Statistics about what was found and changed\r\n */\r\nexport function ingest(projectRoot: string, targetFiles?: string[], options?: IngestOptions): IngestStats {\r\n const extractedDir = join(projectRoot, 'extracted');\r\n const notesDir = join(projectRoot, 'notes');\r\n const namesPath = join(projectRoot, 'db-us', 'names.json');\r\n\r\n const stats: IngestStats = {\r\n filesProcessed: 0,\r\n filesSkipped: 0,\r\n blockNotesFound: 0,\r\n blockNotesNew: 0,\r\n blockNotesUpdated: 0,\r\n blockNotesDeleted: 0,\r\n partNotesFound: 0,\r\n partNotesNew: 0,\r\n partNotesUpdated: 0,\r\n partNotesDeleted: 0,\r\n commentsFound: 0,\r\n commentsNew: 0,\r\n commentsUpdated: 0,\r\n commentsDeleted: 0,\r\n hasLineTracking: false,\r\n };\r\n\r\n // Load names.json for bank detection fallback\r\n const namesLookup = loadNamesBankLookup(namesPath);\r\n\r\n // Find files to process\r\n const asmFiles = targetFiles && targetFiles.length > 0\r\n ? targetFiles\r\n : findAsmFiles(extractedDir);\r\n\r\n if (asmFiles.length === 0) {\r\n console.error('No .asm files found. Run extract or extract:lt first.');\r\n return stats;\r\n }\r\n\r\n console.log(`Scanning ${asmFiles.length} .asm file(s)...\\n`);\r\n\r\n // Phase 1: Parse all files and collect additions + deletion candidates\r\n // Additions/updates\r\n const blockNotesByBank = new Map<number, Map<string, string>>();\r\n const partNotesByBank = new Map<number, Map<string, string>>();\r\n const commentsByBank = new Map<number, Map<number, string>>();\r\n // Deletion candidates\r\n const blockNoteDeletions = new Map<number, Set<string>>();\r\n const partNoteDeletions = new Map<number, Set<string>>();\r\n const commentDeletions = new Map<number, Set<number>>();\r\n\r\n for (const file of asmFiles) {\r\n let parsed: ParsedAnnotations;\r\n try {\r\n parsed = parseFile(file, namesLookup);\r\n } catch (err) {\r\n const relPath = relative(projectRoot, file);\r\n console.warn(` Warning: Failed to parse ${relPath}: ${err}`);\r\n stats.filesSkipped++;\r\n continue;\r\n }\r\n\r\n if (parsed.hasLineTracking) stats.hasLineTracking = true;\r\n\r\n const bank = parsed.bank;\r\n\r\n // --- Block note additions ---\r\n if (parsed.blockNote && bank !== null) {\r\n if (!blockNotesByBank.has(bank)) blockNotesByBank.set(bank, new Map());\r\n blockNotesByBank.get(bank)!.set(parsed.blockNote.name, parsed.blockNote.text);\r\n stats.blockNotesFound++;\r\n if (options?.verbose) {\r\n console.log(` Block note: ${parsed.blockNote.name} → bank${bank.toString(16).toUpperCase().padStart(2, '0')}`);\r\n }\r\n }\r\n\r\n // --- Block note deletion candidate ---\r\n // File has structure but no block note → the block note was removed\r\n if (!parsed.blockNote && parsed.hasStructure && bank !== null) {\r\n if (!blockNoteDeletions.has(bank)) blockNoteDeletions.set(bank, new Set());\r\n blockNoteDeletions.get(bank)!.add(parsed.fileName);\r\n }\r\n\r\n // --- Part note additions ---\r\n if (bank !== null) {\r\n for (const [name, text] of parsed.partNotes) {\r\n if (!partNotesByBank.has(bank)) partNotesByBank.set(bank, new Map());\r\n partNotesByBank.get(bank)!.set(name, text);\r\n stats.partNotesFound++;\r\n if (options?.verbose) {\r\n console.log(` Part note: ${name} → bank${bank.toString(16).toUpperCase().padStart(2, '0')}`);\r\n }\r\n }\r\n\r\n // --- Part note deletion candidates ---\r\n // Labels that appear in the file WITHOUT a preceding part note\r\n for (const label of parsed.allLabels) {\r\n if (!parsed.partNotes.has(label)) {\r\n if (!partNoteDeletions.has(bank)) partNoteDeletions.set(bank, new Set());\r\n partNoteDeletions.get(bank)!.add(label);\r\n }\r\n }\r\n } else if (parsed.partNotes.size > 0) {\r\n const relPath = relative(projectRoot, file);\r\n console.warn(` Warning: Could not determine bank for ${relPath} — skipping ${parsed.partNotes.size} part note(s)`);\r\n }\r\n\r\n // --- Inline comment additions ---\r\n for (const [addr, text] of parsed.comments) {\r\n const commentBank = Math.floor(addr / 65536);\r\n if (!commentsByBank.has(commentBank)) commentsByBank.set(commentBank, new Map());\r\n commentsByBank.get(commentBank)!.set(addr, text);\r\n stats.commentsFound++;\r\n }\r\n\r\n // --- Inline comment deletion candidates ---\r\n // Addresses with ; {address} but no text (only in extract:lt mode)\r\n if (parsed.hasLineTracking) {\r\n for (const addr of parsed.uncommentedAddresses) {\r\n const commentBank = Math.floor(addr / 65536);\r\n if (!commentDeletions.has(commentBank)) commentDeletions.set(commentBank, new Set());\r\n commentDeletions.get(commentBank)!.add(addr);\r\n }\r\n }\r\n\r\n stats.filesProcessed++;\r\n }\r\n\r\n // Phase 2: Report what was found\r\n console.log(`\\nParsed ${stats.filesProcessed} file(s)${stats.filesSkipped > 0 ? ` (${stats.filesSkipped} skipped)` : ''}:`);\r\n console.log(` Block notes: ${stats.blockNotesFound}`);\r\n console.log(` Part notes: ${stats.partNotesFound}`);\r\n console.log(` Comments: ${stats.commentsFound}${stats.hasLineTracking ? '' : ' (no line tracking detected — run extract:lt for inline comments)'}`);\r\n\r\n if (options?.dryRun) {\r\n console.log('\\n[DRY RUN] No files will be written.\\n');\r\n }\r\n\r\n // Phase 3: Merge additions/updates and apply deletions, then write\r\n console.log('\\nMerging with existing notes/...');\r\n\r\n // Collect all bank numbers that need processing\r\n const allBanks = new Set<number>();\r\n for (const bank of blockNotesByBank.keys()) allBanks.add(bank);\r\n for (const bank of blockNoteDeletions.keys()) allBanks.add(bank);\r\n for (const bank of partNotesByBank.keys()) allBanks.add(bank);\r\n for (const bank of partNoteDeletions.keys()) allBanks.add(bank);\r\n for (const bank of commentsByBank.keys()) allBanks.add(bank);\r\n for (const bank of commentDeletions.keys()) allBanks.add(bank);\r\n\r\n for (const bank of [...allBanks].sort()) {\r\n // --- Block notes ---\r\n const bnAdds = blockNotesByBank.get(bank);\r\n const bnDels = blockNoteDeletions.get(bank);\r\n if (bnAdds || bnDels) {\r\n const filePath = join(notesDir, 'blockNotes', bankFileName(bank));\r\n const existing = loadJsonFile(filePath);\r\n let newCount = 0, updatedCount = 0, deletedCount = 0;\r\n\r\n // Additions/updates\r\n if (bnAdds) {\r\n for (const [name, text] of bnAdds) {\r\n if (existing[name] === text) continue;\r\n if (existing[name] !== undefined) { updatedCount++; stats.blockNotesUpdated++; }\r\n else { newCount++; stats.blockNotesNew++; }\r\n existing[name] = text;\r\n }\r\n }\r\n\r\n // Deletions: only delete if the name is NOT being added in this batch\r\n if (bnDels) {\r\n for (const name of bnDels) {\r\n if (bnAdds?.has(name)) continue;\r\n if (existing[name] !== undefined) {\r\n if (options?.verbose) console.log(` Delete block note: ${name}`);\r\n delete existing[name];\r\n deletedCount++;\r\n stats.blockNotesDeleted++;\r\n }\r\n }\r\n }\r\n\r\n if (newCount + updatedCount + deletedCount > 0) {\r\n const relPath = relative(projectRoot, filePath);\r\n const changes = formatChanges(newCount, updatedCount, deletedCount);\r\n if (options?.dryRun) {\r\n console.log(` [DRY] ${relPath}: ${changes}`);\r\n } else if (saveJsonFile(filePath, existing)) {\r\n console.log(` ${relPath}: ${changes}`);\r\n }\r\n }\r\n }\r\n\r\n // --- Part notes ---\r\n const pnAdds = partNotesByBank.get(bank);\r\n const pnDels = partNoteDeletions.get(bank);\r\n if (pnAdds || pnDels) {\r\n const filePath = join(notesDir, 'partNotes', bankFileName(bank));\r\n const existing = loadJsonFile(filePath);\r\n let newCount = 0, updatedCount = 0, deletedCount = 0;\r\n\r\n if (pnAdds) {\r\n for (const [name, text] of pnAdds) {\r\n if (existing[name] === text) continue;\r\n if (existing[name] !== undefined) { updatedCount++; stats.partNotesUpdated++; }\r\n else { newCount++; stats.partNotesNew++; }\r\n existing[name] = text;\r\n }\r\n }\r\n\r\n if (pnDels) {\r\n for (const name of pnDels) {\r\n if (pnAdds?.has(name)) continue;\r\n if (existing[name] !== undefined) {\r\n if (options?.verbose) console.log(` Delete part note: ${name}`);\r\n delete existing[name];\r\n deletedCount++;\r\n stats.partNotesDeleted++;\r\n }\r\n }\r\n }\r\n\r\n if (newCount + updatedCount + deletedCount > 0) {\r\n const relPath = relative(projectRoot, filePath);\r\n const changes = formatChanges(newCount, updatedCount, deletedCount);\r\n if (options?.dryRun) {\r\n console.log(` [DRY] ${relPath}: ${changes}`);\r\n } else if (saveJsonFile(filePath, existing)) {\r\n console.log(` ${relPath}: ${changes}`);\r\n }\r\n }\r\n }\r\n\r\n // --- Comments ---\r\n const cmAdds = commentsByBank.get(bank);\r\n const cmDels = commentDeletions.get(bank);\r\n if (cmAdds || cmDels) {\r\n const filePath = join(notesDir, 'comments', bankFileName(bank));\r\n const existing = loadJsonFile(filePath);\r\n let newCount = 0, updatedCount = 0, deletedCount = 0;\r\n\r\n if (cmAdds) {\r\n for (const [addr, text] of cmAdds) {\r\n const key = addr.toString();\r\n if (existing[key] === text) continue;\r\n if (existing[key] !== undefined) { updatedCount++; stats.commentsUpdated++; }\r\n else { newCount++; stats.commentsNew++; }\r\n existing[key] = text;\r\n }\r\n }\r\n\r\n if (cmDels) {\r\n for (const addr of cmDels) {\r\n const key = addr.toString();\r\n if (cmAdds?.has(addr)) continue;\r\n if (existing[key] !== undefined) {\r\n if (options?.verbose) console.log(` Delete comment: ${key}`);\r\n delete existing[key];\r\n deletedCount++;\r\n stats.commentsDeleted++;\r\n }\r\n }\r\n }\r\n\r\n if (newCount + updatedCount + deletedCount > 0) {\r\n const relPath = relative(projectRoot, filePath);\r\n const changes = formatChanges(newCount, updatedCount, deletedCount);\r\n if (options?.dryRun) {\r\n console.log(` [DRY] ${relPath}: ${changes}`);\r\n } else if (saveJsonFile(filePath, existing)) {\r\n console.log(` ${relPath}: ${changes}`);\r\n }\r\n }\r\n }\r\n }\r\n\r\n // Phase 4: Summary\r\n const totalChanges = stats.blockNotesNew + stats.blockNotesUpdated + stats.blockNotesDeleted\r\n + stats.partNotesNew + stats.partNotesUpdated + stats.partNotesDeleted\r\n + stats.commentsNew + stats.commentsUpdated + stats.commentsDeleted;\r\n\r\n console.log('\\nSummary:');\r\n if (totalChanges === 0) {\r\n console.log(' No changes detected — notes/ is up to date.');\r\n } else {\r\n const bn = stats.blockNotesNew + stats.blockNotesUpdated + stats.blockNotesDeleted;\r\n const pn = stats.partNotesNew + stats.partNotesUpdated + stats.partNotesDeleted;\r\n const cm = stats.commentsNew + stats.commentsUpdated + stats.commentsDeleted;\r\n if (bn > 0) console.log(` Block notes: ${formatChanges(stats.blockNotesNew, stats.blockNotesUpdated, stats.blockNotesDeleted)}`);\r\n if (pn > 0) console.log(` Part notes: ${formatChanges(stats.partNotesNew, stats.partNotesUpdated, stats.partNotesDeleted)}`);\r\n if (cm > 0) console.log(` Comments: ${formatChanges(stats.commentsNew, stats.commentsUpdated, stats.commentsDeleted)}`);\r\n }\r\n\r\n console.log(`\\nIngestion ${options?.dryRun ? '(dry run) ' : ''}complete.`);\r\n return stats;\r\n}\r\n","","","","","","","","","","","","","","","","","","","","","","","","","","","import { fileURLToPath } from 'url';\r\nimport { dirname, join, resolve } from 'path';\r\nimport { existsSync, readdirSync, readFileSync } from 'fs';\r\nimport { DbBlock, DbFile, DbGroup, DbStringType, DbStruct, CopDef, DbFileType, AsmBlock, saveFileAsText, RomProcessingConstants, crc32_buffer } from '@gaialabs/core';\r\nimport { DbRootUtils } from '@gaialabs/core';\r\nimport type { DbAddressingMode, DbConfig, DbGameRomModule } from '@gaialabs/core';\r\nimport { snes } from '@gaialabs/core';\r\nimport { ingest } from './ingest.ts';\r\n\r\nconst __pkgRoot = join(dirname(fileURLToPath(import.meta.url)), '..');\r\n\r\nimport config from '../db-us/config.json' with { type: 'json' };\r\nimport blocks from '../db-us/blocks.json' with { type: 'json' };\r\nimport copdef from '../db-us/copdef.json' with { type: 'json' };\r\nimport files from '../db-us/files.json' with { type: 'json' };\r\nimport groups from '../db-us/groups.json' with { type: 'json' };\r\nimport labels from '../db-us/labels.json' with { type: 'json' };\r\nimport mnemonics from '../db-us/mnemonics.json' with { type: 'json' };\r\nimport overrides from '../db-us/overrides.json' with { type: 'json' };\r\nimport rewrites from '../db-us/rewrites.json' with { type: 'json' };\r\nimport strings from '../db-us/stringTypes.json' with { type: 'json' };\r\nimport structs from '../db-us/structs.json' with { type: 'json' };\r\nimport transforms from '../db-us/transforms.json' with { type: 'json' };\r\nimport fileTypes from '../db-us/fileTypes.json' with { type: 'json' };\r\nimport names from '../db-us/names.json' with { type: 'json' };\r\nimport types from '../db-us/types.json' with { type: 'json' };\r\n\r\nfunction loadNotesDir(subdir: string): Record<string, string> {\r\n const dir = join(__pkgRoot, 'notes', subdir);\r\n if (!existsSync(dir)) return {};\r\n\r\n const merged: Record<string, string> = {};\r\n for (const file of readdirSync(dir)) {\r\n if (!file.endsWith('.json')) continue;\r\n const data = JSON.parse(readFileSync(join(dir, file), 'utf-8'));\r\n Object.assign(merged, data);\r\n }\r\n return merged;\r\n}\r\n\r\nfunction loadLocalNotes(): { comments: Record<string, string>; blockNotes: Record<string, string>; partNotes: Record<string, string> } {\r\n const notesDir = join(__pkgRoot, 'notes');\r\n if (!existsSync(notesDir)) {\r\n return { comments: {}, blockNotes: {}, partNotes: {} };\r\n }\r\n return {\r\n comments: loadNotesDir('comments'),\r\n blockNotes: loadNotesDir('blockNotes'),\r\n partNotes: loadNotesDir('partNotes')\r\n };\r\n}\r\n\r\nimport configJP from '../db-jp/config.json' with { type: 'json' };\r\nimport blocksJP from '../db-jp/blocks.json' with { type: 'json' };\r\nimport copdefJP from '../db-us/copdef.json' with { type: 'json' };\r\nimport filesJP from '../db-jp/files.json' with { type: 'json' };\r\nimport groupsJP from '../db-jp/groups.json' with { type: 'json' };\r\nimport labelsJP from '../db-jp/labels.json' with { type: 'json' };\r\nimport mnemonicsJP from '../db-us/mnemonics.json' with { type: 'json' };\r\nimport overridesJP from '../db-jp/overrides.json' with { type: 'json' };\r\nimport rewritesJP from '../db-jp/rewrites.json' with { type: 'json' };\r\nimport stringsJP from '../db-jp/stringTypes.json' with { type: 'json' };\r\nimport structsJP from '../db-jp/structs.json' with { type: 'json' };\r\nimport transformsJP from '../db-jp/transforms.json' with { type: 'json' };\r\nimport fileTypesJP from '../db-us/fileTypes.json' with { type: 'json' };\r\nimport namesJP from '../db-jp/names.json' with { type: 'json' };\r\n\r\nconst localNotes = loadLocalNotes();\r\n\r\nexport const db : DbGameRomModule = {\r\n mnemonics: { ...snes.vectors, ...mnemonics },\r\n overrides: overrides as unknown as Record<string, Record<string, number>>,\r\n rewrites,\r\n blocks: blocks as unknown as Record<string, Record<string, Partial<DbBlock>>>,\r\n copdef: copdef as unknown as Record<string, Partial<CopDef>>,\r\n files: files as unknown as Record<string, Record<string, Record<string, Partial<DbFile>>>>,\r\n groups: groups as unknown as Record<string, Partial<DbGroup>>,\r\n labels, //: labels as unknown as Record<string, string>,\r\n strings: strings as unknown as Record<string, Partial<DbStringType>>,\r\n structs: structs as unknown as Record<string, DbStruct>,\r\n transforms,\r\n config: config as unknown as DbConfig,\r\n fileTypes: fileTypes as unknown as Record<string, Partial<DbFileType>>,\r\n addrModes: snes.addressingModes as unknown as Record<string, Partial<DbAddressingMode>>,\r\n headers: snes.headers,\r\n names,\r\n types,\r\n comments: localNotes.comments,\r\n blockNotes: localNotes.blockNotes,\r\n partNotes: localNotes.partNotes\r\n};\r\n\r\nexport const jp : DbGameRomModule = {\r\n mnemonics: { ...snes.vectors, ...mnemonicsJP },\r\n overrides: overridesJP as unknown as Record<string, Record<string, number>>,\r\n rewrites: rewritesJP,\r\n blocks: blocksJP as unknown as Record<string, Record<string, Partial<DbBlock>>>,\r\n copdef: copdefJP as unknown as Record<string, Partial<CopDef>>,\r\n files: filesJP as unknown as Record<string, Record<string, Record<string, Partial<DbFile>>>>,\r\n groups: groupsJP as unknown as Record<string, Partial<DbGroup>>,\r\n labels: labelsJP, // as unknown as Record<number, string>,\r\n strings: stringsJP as unknown as Record<string, Partial<DbStringType>>,\r\n structs: { ...structs, ...structsJP } as unknown as Record<string, DbStruct>,\r\n transforms: transformsJP,\r\n config: configJP as unknown as DbConfig,\r\n fileTypes: fileTypesJP as unknown as Record<string, Partial<DbFileType>>,\r\n addrModes: snes.addressingModes as unknown as Record<string, Partial<DbAddressingMode>>,\r\n headers: snes.headers,\r\n names: namesJP\r\n};\r\n\r\nexport async function extract(romPath: string, outPath: string, options?: string[]) {\r\n if (!romPath) romPath = process.env.ROM_PATH;\r\n if(!outPath) outPath = './extracted';\r\n\r\n var dbRoot = DbRootUtils.fromGameModule(db);\r\n\r\n if(options?.includes('linetracking')) dbRoot.config.emitLineTracking = true;\r\n\r\n await DbRootUtils.extractAllContent(dbRoot, romPath, outPath);\r\n}\r\n\r\nexport async function extractJP(romPath: string, outPath: string) {\r\n if (!romPath) romPath = process.env.ROM_PATH_JP;\r\n if(!outPath) outPath = './extracted-jp';\r\n\r\n var dbRoot = DbRootUtils.fromGameModule(jp);\r\n\r\n await DbRootUtils.extractAllContent(dbRoot, romPath, outPath);\r\n}\r\n\r\nexport async function rebuild(inPath: string, outPath: string, baseRomPath: string, modulePaths?: string[], options?: string[]) {\r\n if(!inPath) inPath = './extracted';\r\n if(!outPath) outPath = `./rebuilt/${process.env.ROM_NAME ?? 'Illusion of Gaia - Rebuilt'}.smc`;\r\n if(!baseRomPath) baseRomPath = join(__pkgRoot, 'baserom');\r\n \r\n var dbRoot = DbRootUtils.fromGameModule(db);\r\n\r\n const outData = await DbRootUtils.rebuildAllContent(dbRoot, [inPath, baseRomPath, ...(modulePaths || [])], outPath);\r\n \r\n if(options?.includes('artifacts')) {\r\n console.log('Generating artifacts...');\r\n const artifactPath = './artifacts';\r\n let totalSize = 0;\r\n\r\n const fileLayoutArtifact = outData.files.filter((file) => file.size > 0).sort((a, b) => a.location - b.location).map((file) => {\r\n totalSize += file.size;\r\n return ` \"${file.location.toString(16).toUpperCase().padStart(6, '0')}\" : \"${file.name}\"`;\r\n });\r\n\r\n const fileLayoutArtifactText = `{${RomProcessingConstants.NEWLINE}${fileLayoutArtifact.join(',' + RomProcessingConstants.NEWLINE)}${RomProcessingConstants.NEWLINE}}`;\r\n await saveFileAsText(join(artifactPath, 'file-layout.json'), fileLayoutArtifactText);\r\n\r\n const masterArtifact = Object.entries(outData.masterLookup)\r\n .filter((entry) => !entry[0].match(/[!+-]$/))\r\n .sort((a, b) => a[1].location - b[1].location)\r\n .map((entry) => {\r\n return ` \"${entry[0]}\": \"${entry[1].location.toString(16).toUpperCase().padStart(6, '0')}\"`;\r\n });\r\n\r\n const masterArtifactText = `{${RomProcessingConstants.NEWLINE}${masterArtifact.join(',' + RomProcessingConstants.NEWLINE)}${RomProcessingConstants.NEWLINE}}`;\r\n await saveFileAsText(join(artifactPath, 'master-lookup.json'), masterArtifactText);\r\n\r\n const crc = crc32_buffer(outData.romData);\r\n const crcText = JSON.stringify({ checksum: outData.header.checksum, crc, totalSize }, null, 2);\r\n await saveFileAsText(join(artifactPath, 'crc.json'), crcText);\r\n }\r\n}\r\n\r\nexport async function rebuildJp(inPath: string, outPath: string, baseRomPath: string, modulePaths?: string[]) {\r\n if(!inPath) inPath = './extracted-jp';\r\n if(!outPath) outPath = `./rebuilt-jp/${process.env.ROM_NAME_JP ?? 'Gaia Gensouki - Rebuilt'}.smc`;\r\n if(!baseRomPath) baseRomPath = join(__pkgRoot, 'baserom-jp');\r\n \r\n var dbRoot = DbRootUtils.fromGameModule(jp);\r\n\r\n await DbRootUtils.rebuildAllContent(dbRoot, [inPath, baseRomPath, ...(modulePaths || [])], outPath);\r\n}\r\n\r\n// CLI handler - only execute when run directly (not when imported as a module)\r\n// Check if this module is being run directly\r\nconst isMainModule = resolve(process.argv[1] || '') === fileURLToPath(import.meta.url);\r\n\r\nif (isMainModule) {\r\n const command = process.argv[2];\r\n const args = process.argv.slice(3);\r\n\r\n const flags = [];\r\n for(let index = 0; index < args.length; index++) {\r\n const arg = args[index];\r\n if(arg.startsWith('--')) {\r\n flags.push(arg.slice(2).toLowerCase());\r\n args.splice(index, 1);\r\n index--;\r\n }\r\n }\r\n\r\n // const options = flags.reduce((acc, flag) => {\r\n // acc[flag] = true;\r\n // return acc;\r\n // }, {});\r\n\r\n (async () => {\r\n try {\r\n switch (command) {\r\n case 'extract':\r\n console.log('Starting ROM extraction...');\r\n console.log('ROM Path:', args[0]);\r\n console.log('Output Path:', args[1] || '../extracted');\r\n await extract(args[0], args[1], flags);\r\n console.log('ROM extraction completed successfully!');\r\n break;\r\n case 'extract-jp':\r\n console.log('Starting ROM extraction...');\r\n console.log('ROM Path:', args[0]);\r\n console.log('Output Path:', args[1] || '../extracted-jp');\r\n await extractJP(args[0], args[1]);\r\n console.log('ROM extraction completed successfully!');\r\n break;\r\n case 'rebuild':\r\n console.log('Starting ROM rebuild...');\r\n await rebuild(args[0], args[1], args[2], undefined, flags);\r\n console.log('ROM rebuild completed successfully!');\r\n break;\r\n case 'rebuild-jp':\r\n console.log('Starting JP ROM rebuild...');\r\n await rebuild(args[0], args[1], args[2]);\r\n console.log('ROM rebuild completed successfully!');\r\n break;\r\n case 'ingest':\r\n console.log('Starting notes ingestion...\\n');\r\n ingest(__pkgRoot, args.length > 0 ? args : undefined, {\r\n dryRun: flags.includes('dry-run') || flags.includes('dryrun'),\r\n verbose: flags.includes('verbose'),\r\n });\r\n break;\r\n default:\r\n console.error('Unknown command:', command);\r\n console.log('Available commands: extract, extract-jp, rebuild, rebuild-jp, ingest');\r\n process.exit(1);\r\n }\r\n } catch (error) {\r\n console.error('Error:', error);\r\n process.exit(1);\r\n }\r\n })();\r\n}\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsEA,SAAS,oBAAoB,WAAwC;CACjE,MAAM,yBAAS,IAAI,IAAoB;CACvC,IAAI,CAAC,WAAW,SAAS,GAAG,OAAO;CACnC,IAAI;EACA,MAAM,QAAgC,KAAK,MAAM,aAAa,WAAW,OAAO,CAAC;EACjF,KAAK,MAAM,CAAC,MAAM,SAAS,OAAO,QAAQ,KAAK,GAAG;GAC9C,MAAM,UAAU,SAAS,MAAM,EAAE;GACjC,IAAI,CAAC,MAAM,OAAO,GACd,OAAO,IAAI,MAAM,KAAK,MAAM,UAAU,KAAK,CAAC;EAEpD;CACJ,QAAQ,CAA4B;CACpC,OAAO;AACX;;;;AAKA,SAAS,WAA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AAwC;KACpD;IACJ,KAAK;KACD,QAAQ,IAAI,yBAAyB;KACrC,MAAM,QAAQ,KAAK,IAAI,KAAK,IAAI,KAAK,IAAI,QAAW,KAAK;KACzD,QAAQ,IAAI,qCAAqC;KACjD;IACJ,KAAK;KACD,QAAQ,IAAI,4BAA4B;KACxC,MAAM,QAAQ,KAAK,IAAI,KAAK,IAAI,KAAK,EAAE;KACvC,QAAQ,IAAI,qCAAqC;KACjD;IACJ,KAAK;KACD,QAAQ,IAAI,+BAA+B;KAC3C,OAAO,WAAW,KAAK,SAAS,IAAI,OAAO,QAAW;MAClD,QAAQ,MAAM,SAAS,SAAS,KAAK,MAAM,SAAS,QAAQ;MAC5D,SAAS,MAAM,SAAS,SAAS;KACrC,CAAC;KACD;IACJ;KACI,QAAQ,MAAM,oBAAoB,OAAO;KACzC,QAAQ,IAAI,sEAAsE;KAClF,QAAQ,KAAK,CAAC;GACtB;EACJ,SAAS,OAAO;GACZ,QAAQ,MAAM,UAAU,KAAK;GAC7B,QAAQ,KAAK,CAAC;EAClB;CACJ,EAAC,CAAE;AACP"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gaialabs/iog-baserom",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.6",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "GaiaLabs IOG Base ROM",
|
|
6
6
|
"funding": "https://github.com/sponsors/Azarem",
|
|
@@ -27,7 +27,10 @@
|
|
|
27
27
|
"extract:lt": "rm -rf extracted/* && node --env-file=.env.local src/index.ts extract --linetracking",
|
|
28
28
|
"extract-jp": "rm -rf extracted-jp && node --env-file=.env.local src/index.ts extract-jp",
|
|
29
29
|
"rebuild": "node src/index.ts rebuild --artifacts",
|
|
30
|
-
"rebuild-jp": "node src/index.ts rebuild-jp"
|
|
30
|
+
"rebuild-jp": "node src/index.ts rebuild-jp",
|
|
31
|
+
"ingest": "node src/index.ts ingest",
|
|
32
|
+
"ingest:dry": "node src/index.ts ingest --dry-run",
|
|
33
|
+
"ingest:verbose": "node src/index.ts ingest --verbose"
|
|
31
34
|
},
|
|
32
35
|
"dependencies": {
|
|
33
36
|
"@gaialabs/core": "1.0.5"
|
package/baserom/widescreen.bso
DELETED
|
File without changes
|
|
File without changes
|
|
File without changes
|