Skip to content

ROM Version Queries for Hardware Memory Extraction#39

Open
unreference wants to merge 6 commits into
HarbourMasters:developfrom
unreference:feat/hardware-memory-limits
Open

ROM Version Queries for Hardware Memory Extraction#39
unreference wants to merge 6 commits into
HarbourMasters:developfrom
unreference:feat/hardware-memory-limits

Conversation

@unreference
Copy link
Copy Markdown

@unreference unreference commented May 11, 2026

Part 1/3 of Hardware Memory Limits, depended on by OTRExporter #47 and Shipwright #6609.

Adds version detection methods and a public version getter to ZRom for use by OTRExporter's hardware memory data extraction.

  • IsDebug(): Returns true for GC debug ROMs
  • IsN64(): Returns true for all N64-platform ROMs
  • GetVersion(): Exposes the detected RomVersion struct
  • RomVersion gets promoted from a standalone struct to a ZRom member with public const-ref getter

Used by OTRExporter to determine the ArenaNode size: N64 unconditionally includes fields in __osMalloc (node = 0x30), while GC retail compiles them out (node = 0x10). The detection logic is rom.IsN64() || rom.IsDebug().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant