mirror of
https://github.com/Fledge68/WiiFlow_Lite.git
synced 2024-12-18 07:51:53 +01:00
-fixed reading in scummvm game list for sure now,
shouldn't codedump anymore with too long game titles, games from usb should also work fine now
This commit is contained in:
parent
ac5ffef989
commit
9d9636f080
@ -123,17 +123,18 @@ safe_vector<dir_discHdr> Plugin::ParseScummvmINI(Config &ini, string Device)
|
|||||||
dir_discHdr tmp;
|
dir_discHdr tmp;
|
||||||
while(1)
|
while(1)
|
||||||
{
|
{
|
||||||
if(game != emptyString && (lowerCase(game).rfind("scummvm") != string::npos
|
if(game == emptyString)
|
||||||
|| lowerCase(ini.getString(game, "path")).rfind(Device) == string::npos))
|
break;
|
||||||
|
if(strncasecmp(game.c_str(), "/", 1) == 0 ||
|
||||||
|
lowerCase(game).rfind("scummvm") != string::npos ||
|
||||||
|
lowerCase(ini.getStrings(game, "path", '/')[0]).rfind(Device.c_str()) == string::npos)
|
||||||
{
|
{
|
||||||
game = ini.nextDomain();
|
game = ini.nextDomain();
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if(game == emptyString)
|
|
||||||
break;
|
|
||||||
memset(&tmp, 0, sizeof(dir_discHdr));
|
memset(&tmp, 0, sizeof(dir_discHdr));
|
||||||
tmp.hdr.casecolor = caseColors.back();
|
tmp.hdr.casecolor = caseColors.back();
|
||||||
mbstowcs(tmp.title, ini.getString(game,"description").c_str(), sizeof(tmp.title));
|
mbstowcs(tmp.title, ini.getString(game,"description").c_str(), 64);
|
||||||
strncpy(tmp.path, game.c_str(), sizeof(tmp.path));
|
strncpy(tmp.path, game.c_str(), sizeof(tmp.path));
|
||||||
gprintf("Found: %s\n", ini.getString(game,"description").c_str());
|
gprintf("Found: %s\n", ini.getString(game,"description").c_str());
|
||||||
tmp.hdr.magic = magicWords.back();
|
tmp.hdr.magic = magicWords.back();
|
||||||
|
Loading…
Reference in New Issue
Block a user