mchlnix / SMB3-Foundry

SMB3 Level Editor in Python
GNU General Public License v3.0
93 stars 12 forks source link

New parser NESMemory class breaks expanded ROMs #142

Closed fortenbt closed 2 years ago

fortenbt commented 2 years ago

On initialization, the NESMemory class loads banks 30 and 31 rather than "the last two" PRG banks depending upon PRG size.

https://github.com/mchlnix/SMB3-Foundry/blob/c367a66600b16be26bc3d8e4dd6e01a7e49d7fe7/smb3parse/util/parser/memory.py

This will have interesting effects when using the emulation. Because of rom.py's prg_normalize, most or all of the accesses of the last two banks' data values will be correct, but emulation I believe will be running whatever code is in bank 30 and 31.