mirror of
https://github.com/RetroDECK/Supermodel.git
synced 2025-02-18 02:05:39 +00:00
Changes by Harry Tuttle: game list more accurately reflects MAME's, added a root level XML "games" node, print ROM version along with title
This commit is contained in:
parent
f6707ecfba
commit
c013eab711
1098
Config/Games.xml
1098
Config/Games.xml
File diff suppressed because it is too large
Load diff
|
@ -236,9 +236,14 @@ static void PopulateGameInfo(Game *game, const Util::Config::Node &game_node)
|
||||||
bool GameLoader::LoadGamesFromXML(const Util::Config::Node &xml)
|
bool GameLoader::LoadGamesFromXML(const Util::Config::Node &xml)
|
||||||
{
|
{
|
||||||
for (auto it = xml.begin(); it != xml.end(); ++it)
|
for (auto it = xml.begin(); it != xml.end(); ++it)
|
||||||
|
{
|
||||||
|
// Root games node
|
||||||
|
auto &root_node = *it;
|
||||||
|
if (root_node.Key() != "games")
|
||||||
|
continue;
|
||||||
|
for (auto &game_node: root_node)
|
||||||
{
|
{
|
||||||
// Game node
|
// Game node
|
||||||
auto &game_node = *it;
|
|
||||||
if (game_node.Key() != "game")
|
if (game_node.Key() != "game")
|
||||||
continue;
|
continue;
|
||||||
if (game_node["name"].Empty())
|
if (game_node["name"].Empty())
|
||||||
|
@ -309,7 +314,7 @@ bool GameLoader::LoadGamesFromXML(const Util::Config::Node &xml)
|
||||||
if (regions_by_name.empty())
|
if (regions_by_name.empty())
|
||||||
ErrorLog("%s: No ROM regions defined for '%s'.", m_xml_filename.c_str(), game_name.c_str());
|
ErrorLog("%s: No ROM regions defined for '%s'.", m_xml_filename.c_str(), game_name.c_str());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
// Check to ensure some games were defined
|
// Check to ensure some games were defined
|
||||||
if (m_regions_by_game.empty())
|
if (m_regions_by_game.empty())
|
||||||
{
|
{
|
||||||
|
|
|
@ -2551,7 +2551,7 @@ void CModel3::Reset(void)
|
||||||
// Apply patches to games
|
// Apply patches to games
|
||||||
static void Patch(uint8_t *crom, const Game &game)
|
static void Patch(uint8_t *crom, const Game &game)
|
||||||
{
|
{
|
||||||
if (game.name == "scudp")
|
if (game.name == "scudplus" || game.name == "scudplusa") // No patching?
|
||||||
{
|
{
|
||||||
// Base offset of program in CROM: 0x710000
|
// Base offset of program in CROM: 0x710000
|
||||||
}
|
}
|
||||||
|
@ -2568,7 +2568,7 @@ static void Patch(uint8_t *crom, const Game &game)
|
||||||
{
|
{
|
||||||
*(UINT32 *) &crom[0x7374f4] = 0x38840004; // an actual bug in the game code
|
*(UINT32 *) &crom[0x7374f4] = 0x38840004; // an actual bug in the game code
|
||||||
}
|
}
|
||||||
else if (game.name == "vs215" || game.name == "vs215o" || game.name == "vs29815")
|
else if (game.name == "vs215" || game.name == "vs215o" || game.name == "vs29815" || game.name == "vs29915")
|
||||||
{
|
{
|
||||||
// VS215 is a modification of VS2 that runs on Step 1.5 hardware. I
|
// VS215 is a modification of VS2 that runs on Step 1.5 hardware. I
|
||||||
// suspect the code here is trying to detect the system type but am too
|
// suspect the code here is trying to detect the system type but am too
|
||||||
|
@ -2590,13 +2590,13 @@ static void Patch(uint8_t *crom, const Game &game)
|
||||||
*(UINT32 *) &crom[0x7C0C8] = 0x60000000;
|
*(UINT32 *) &crom[0x7C0C8] = 0x60000000;
|
||||||
*(UINT32 *) &crom[0x7C0CC] = 0x60000000;
|
*(UINT32 *) &crom[0x7C0CC] = 0x60000000;
|
||||||
}
|
}
|
||||||
else if (game.name == "harley")
|
else if (game.name == "harleya")
|
||||||
{
|
{
|
||||||
*(UINT32 *) &crom[0x50E8D4] = 0x60000000;
|
*(UINT32 *) &crom[0x50E8D4] = 0x60000000;
|
||||||
*(UINT32 *) &crom[0x50E8F4] = 0x60000000;
|
*(UINT32 *) &crom[0x50E8F4] = 0x60000000;
|
||||||
*(UINT32 *) &crom[0x50FB84] = 0x60000000;
|
*(UINT32 *) &crom[0x50FB84] = 0x60000000;
|
||||||
}
|
}
|
||||||
else if (game.name == "harleyb")
|
else if (game.name == "harley")
|
||||||
{
|
{
|
||||||
*(UINT32 *) &crom[0x50ECB4] = 0x60000000;
|
*(UINT32 *) &crom[0x50ECB4] = 0x60000000;
|
||||||
*(UINT32 *) &crom[0x50ECD4] = 0x60000000;
|
*(UINT32 *) &crom[0x50ECD4] = 0x60000000;
|
||||||
|
@ -2613,7 +2613,7 @@ static void Patch(uint8_t *crom, const Game &game)
|
||||||
{
|
{
|
||||||
*(UINT32 *) &crom[0xF6DD0] = 0x60000000; // from MAME
|
*(UINT32 *) &crom[0xF6DD0] = 0x60000000; // from MAME
|
||||||
}
|
}
|
||||||
else if (game.name == "eca" || game.name == "ecax")
|
else if (game.name == "eca" || game.name == "ecau")
|
||||||
{
|
{
|
||||||
*(UINT32 *) &crom[0x535580] = 0x60000000;
|
*(UINT32 *) &crom[0x535580] = 0x60000000;
|
||||||
//*(UINT32 *) &crom[0x5023B4] = 0x60000000;
|
//*(UINT32 *) &crom[0x5023B4] = 0x60000000;
|
||||||
|
@ -2819,6 +2819,9 @@ bool CModel3::LoadGame(const Game &game, const ROMSet &rom_set)
|
||||||
extra_hw.insert("Drive Board");
|
extra_hw.insert("Drive Board");
|
||||||
if (game.encryption_key)
|
if (game.encryption_key)
|
||||||
extra_hw.insert("Security Board");
|
extra_hw.insert("Security Board");
|
||||||
|
if (!game.version.empty())
|
||||||
|
std::cout << " Title: " << game.title << " (" << game.version << ")" << std::endl;
|
||||||
|
else
|
||||||
std::cout << " Title: " << game.title << std::endl;
|
std::cout << " Title: " << game.title << std::endl;
|
||||||
std::cout << " ROM Set: " << game.name << std::endl;
|
std::cout << " ROM Set: " << game.name << std::endl;
|
||||||
std::cout << " Developer: " << game.manufacturer << std::endl;
|
std::cout << " Developer: " << game.manufacturer << std::endl;
|
||||||
|
|
|
@ -1220,6 +1220,9 @@ static void PrintGameList(const std::string &xml_file, const std::map<std::strin
|
||||||
printf(" %s", game.name.c_str());
|
printf(" %s", game.name.c_str());
|
||||||
for (int i = game.name.length(); i < 9; i++) // pad for alignment (no game ID should be more than 9 letters)
|
for (int i = game.name.length(); i < 9; i++) // pad for alignment (no game ID should be more than 9 letters)
|
||||||
printf(" ");
|
printf(" ");
|
||||||
|
if (!game.version.empty())
|
||||||
|
printf(" %s (%s)\n", game.title.c_str(), game.version.c_str());
|
||||||
|
else
|
||||||
printf(" %s\n", game.title.c_str());
|
printf(" %s\n", game.title.c_str());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue