Skip to content
This repository has been archived by the owner on Sep 11, 2023. It is now read-only.

Add submapper 1 support to Coolboy (mapper 268) #79

Merged
merged 1 commit into from
Mar 12, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Core/MMC3_Coolboy.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class MMC3_Coolboy : public MMC3
uint8_t _exRegs[4];

protected:
uint16_t RegisterStartAddress() override { return 0x6000; }
uint16_t RegisterStartAddress() override { return _romInfo.SubMapperID == 1 ? 0x5000 : 0x6000; }
uint32_t GetChrRamSize() override { return 0x40000; }

void Reset(bool softReset) override
Expand Down Expand Up @@ -95,7 +95,7 @@ class MMC3_Coolboy : public MMC3
WritePrgRam(addr, value);
}

if((_exRegs[3] & 0x90) != 0x80) {
if(((_romInfo.SubMapperID != 1) || (addr < 0x6000)) && (_exRegs[3] & 0x90) != 0x80) {
_exRegs[addr & 0x03] = value;
UpdateState();
}
Expand Down