mirror of https://github.com/bsnes-emu/bsnes.git
Add an HuC command required by Pocket Family 2
This commit is contained in:
parent
a9023d08c6
commit
a588993f28
|
@ -568,6 +568,7 @@ static void write_mbc_ram(GB_gameboy_t *gb, uint16_t addr, uint8_t value)
|
|||
}
|
||||
gb->huc3_access_index++;
|
||||
return;
|
||||
case 2:
|
||||
case 3:
|
||||
if (gb->huc3_access_index < 3) {
|
||||
gb->huc3_minutes &= ~(0xF << (gb->huc3_access_index * 4));
|
||||
|
@ -577,7 +578,9 @@ static void write_mbc_ram(GB_gameboy_t *gb, uint16_t addr, uint8_t value)
|
|||
gb->huc3_days &= ~(0xF << ((gb->huc3_access_index - 3) * 4));
|
||||
gb->huc3_days |= ((value & 0xF) << ((gb->huc3_access_index - 3) * 4));
|
||||
}
|
||||
gb->huc3_access_index++;
|
||||
if ((value >> 4) == 3) {
|
||||
gb->huc3_access_index++;
|
||||
}
|
||||
return;
|
||||
case 4:
|
||||
gb->huc3_access_index &= 0xF0;
|
||||
|
|
Loading…
Reference in New Issue