mirror of
https://github.com/ekeeke/Genesis-Plus-GX.git
synced 2024-11-13 06:15:07 +01:00
[Core/MS] fixed savestate support when using Boot ROM
This commit is contained in:
parent
eeea2039b6
commit
f9161fbcee
@ -777,11 +777,45 @@ int sms_cart_context_load(uint8 *state)
|
||||
{
|
||||
/* load Boot ROM mapper settings */
|
||||
load_param(bios_rom.fcr, 4);
|
||||
|
||||
/* set default cartridge ROM paging */
|
||||
switch (cart_rom.mapper)
|
||||
{
|
||||
case MAPPER_SEGA:
|
||||
case MAPPER_SEGA_X:
|
||||
cart_rom.fcr[0] = 0;
|
||||
cart_rom.fcr[1] = 0;
|
||||
cart_rom.fcr[2] = 1;
|
||||
cart_rom.fcr[3] = 2;
|
||||
break;
|
||||
|
||||
case MAPPER_KOREA_8K:
|
||||
case MAPPER_MSX:
|
||||
case MAPPER_MSX_NEMESIS:
|
||||
cart_rom.fcr[0] = 0;
|
||||
cart_rom.fcr[1] = 0;
|
||||
cart_rom.fcr[2] = 0;
|
||||
cart_rom.fcr[3] = 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
cart_rom.fcr[0] = 0;
|
||||
cart_rom.fcr[1] = 0;
|
||||
cart_rom.fcr[2] = 1;
|
||||
cart_rom.fcr[3] = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* load cartridge mapper settings */
|
||||
load_param(cart_rom.fcr, 4);
|
||||
|
||||
/* set default BIOS ROM paging (SEGA mapper by default) */
|
||||
bios_rom.fcr[0] = 0;
|
||||
bios_rom.fcr[1] = 0;
|
||||
bios_rom.fcr[2] = 1;
|
||||
bios_rom.fcr[3] = 2;
|
||||
}
|
||||
|
||||
/* support for SG-1000 games with extra RAM */
|
||||
|
Loading…
Reference in New Issue
Block a user