More detailed error messages when encrypted titles fail to launch

This commit is contained in:
Exzap 2023-09-27 12:38:51 +02:00
parent 5ad57bb0c9
commit f6c3c96d94
5 changed files with 81 additions and 15 deletions

View file

@ -559,6 +559,16 @@ bool MainWindow::FileLoad(std::wstring fileName, wxLaunchGameEvent::INITIATED_BY
{
wxString t = _("Unable to launch game\nPath:\n");
t.append(fileName);
if(launchTitle.GetInvalidReason() == TitleInfo::InvalidReason::NO_DISC_KEY)
{
t.append(_("\n\n"));
t.append(_("Could not decrypt title. Make sure that keys.txt contains the correct disc key for this title."));
}
if(launchTitle.GetInvalidReason() == TitleInfo::InvalidReason::NO_TITLE_TIK)
{
t.append(_(""));
t.append(_("\n\nCould not decrypt title because title.tik is missing."));
}
wxMessageBox(t, _("Error"), wxOK | wxCENTRE | wxICON_ERROR);
return false;
}