famiclom
famiclom copied to clipboard
get-bank issue?
Early in Mega Man 2 init, get-bank returns 31 which is the value stored in the mapper accumulator register. However, the cartridge only has 16 rom banks. We promptly try to read from an address off the end of the array and error.
It is unclear to me whether:
- A) the return value from get-bank should be wrapped with a logical and whether in get-bank or its caller. or,
- B) the value should never have been allowed into the accumulator reg in the first place.