mirror of https://github.com/LIJI32/SameBoy.git
Fix a bug causing newly imported ROMs to sometime incorrectly prefer SGB over CGB
This commit is contained in:
parent
e5e9cf145a
commit
2bf8feb299
|
@ -491,9 +491,11 @@ static void rumbleCallback(GB_gameboy_t *gb, double amp)
|
|||
// Newly played ROM, pick the best model
|
||||
uint8_t *rom = GB_get_direct_access(&_gb, GB_DIRECT_ACCESS_ROM, NULL, NULL);
|
||||
|
||||
if ((rom[0x143] & 0x80) && !GB_is_cgb(&_gb)) {
|
||||
if ((rom[0x143] & 0x80)) {
|
||||
if (!GB_is_cgb(&_gb)) {
|
||||
GB_switch_model_and_reset(&_gb, [[NSUserDefaults standardUserDefaults] integerForKey:@"GBCGBModel"]);
|
||||
}
|
||||
}
|
||||
else if ((rom[0x146] == 3) && !GB_is_sgb(&_gb)) {
|
||||
GB_switch_model_and_reset(&_gb, [[NSUserDefaults standardUserDefaults] integerForKey:@"GBSGBModel"]);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue