Merge pull request #5981 from celerizer/master

Support Neo Geo Pocket
This commit is contained in:
Twinaphex 2017-12-29 00:13:22 +01:00 committed by GitHub
commit 946b765e61
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View File

@ -63,7 +63,7 @@ typedef enum
CHEEVOS_CONSOLE_MASTER_SYSTEM = 11,
CHEEVOS_CONSOLE_PLAYSTATION = 12,
CHEEVOS_CONSOLE_ATARI_LYNX = 13,
CHEEVOS_CONSOLE_NEOGEO = 14,
CHEEVOS_CONSOLE_NEOGEO_POCKET = 14,
CHEEVOS_CONSOLE_XBOX_360 = 15,
CHEEVOS_CONSOLE_GAMECUBE = 16,
CHEEVOS_CONSOLE_ATARI_JAGUAR = 17,

View File

@ -191,6 +191,12 @@ void cheevos_var_patch_addr(cheevos_var_t* var, cheevos_console_t console)
var->value -= 0x2000;
}
}
else if (console == CHEEVOS_CONSOLE_NEOGEO_POCKET)
{
if (var->value >= 0x4000 && var->value <= 0x7fff)
CHEEVOS_LOG(CHEEVOS_TAG "NGP memory address %X adjusted to %X\n", var->value, var->value - 0x004000);
var->value -= 0x4000;
}
if (system->mmaps.num_descriptors != 0)
{