mirror of https://github.com/stella-emu/stella.git
Properly handle 'Cart.StartBank' set to 'AUTO' in the ROM properties.
This commit is contained in:
parent
f1d18b6f0d
commit
c3a8543dc4
|
@ -119,7 +119,8 @@ Console::Console(OSystem& osystem, unique_ptr<Cartridge>& cart,
|
||||||
// Let the cart know how to query for the 'Cartridge.StartBank' property
|
// Let the cart know how to query for the 'Cartridge.StartBank' property
|
||||||
myCart->setStartBankFromPropsFunc([this]() {
|
myCart->setStartBankFromPropsFunc([this]() {
|
||||||
const string& startbank = myProperties.get(PropType::Cart_StartBank);
|
const string& startbank = myProperties.get(PropType::Cart_StartBank);
|
||||||
return startbank == EmptyString ? -1 : atoi(startbank.c_str());
|
return (startbank == EmptyString || BSPF::equalsIgnoreCase(startbank, "AUTO"))
|
||||||
|
? -1 : atoi(startbank.c_str());
|
||||||
});
|
});
|
||||||
|
|
||||||
// We can only initialize after all the devices/components have been created
|
// We can only initialize after all the devices/components have been created
|
||||||
|
|
|
@ -314,7 +314,7 @@ string Properties::ourDefaultProperties[static_cast<uInt8>(PropType::NumTypes)]
|
||||||
"", // Cart.Note
|
"", // Cart.Note
|
||||||
"", // Cart.Rarity
|
"", // Cart.Rarity
|
||||||
"MONO", // Cart.Sound
|
"MONO", // Cart.Sound
|
||||||
"", // Cart.StartBank
|
"AUTO", // Cart.StartBank
|
||||||
"AUTO", // Cart.Type
|
"AUTO", // Cart.Type
|
||||||
"B", // Console.LeftDiff
|
"B", // Console.LeftDiff
|
||||||
"B", // Console.RightDiff
|
"B", // Console.RightDiff
|
||||||
|
|
Loading…
Reference in New Issue