Skip to content

Commit

Permalink
Fix reading custom titles from WAD files
Browse files Browse the repository at this point in the history
  • Loading branch information
Stevoisiak committed Jul 5, 2015
1 parent 90167ab commit afc1398
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Source/Core/DolphinWX/GameListCtrl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -408,9 +408,15 @@ void CGameListCtrl::InsertItemInReportView(long _Index)
break;

const size_t equals_index = line.find('=');
if (line.substr(0, equals_index - 1) == rISOFile.GetUniqueID())
std::string game_id = rISOFile.GetUniqueID();

// Ignore publisher ID for WAD files
if (rISOFile.GetPlatform() == DiscIO::IVolume::WII_WAD)
game_id.erase(game_id.size() - 2);

if (line.substr(0, equals_index - 1) == game_id)
{
name = StrToWxStr(line.substr(equals_index + 2));
name = StrToWxStr(StripSpaces(line.substr(equals_index + 1)));
break;
}
}
Expand Down

0 comments on commit afc1398

Please sign in to comment.