mirror of
https://github.com/PabloMK7/citra.git
synced 2025-09-10 12:50:04 +00:00
Artic Base: Implement DLC support and other fixes (#173)
* Artic Base: Implement DLC support and other fixes * Fix per game settings not working with artic loader * Fix compilation error
This commit is contained in:
parent
1e2be72e5e
commit
4780a7134d
16 changed files with 992 additions and 236 deletions
|
@ -151,7 +151,14 @@ void ConfigurePerGame::LoadConfiguration() {
|
|||
ui->display_title_id->setText(
|
||||
QStringLiteral("%1").arg(title_id, 16, 16, QLatin1Char{'0'}).toUpper());
|
||||
|
||||
const auto loader = Loader::GetLoader(filename);
|
||||
std::unique_ptr<Loader::AppLoader> loader_ptr;
|
||||
Loader::AppLoader* loader;
|
||||
if (system.IsPoweredOn()) {
|
||||
loader = &system.GetAppLoader();
|
||||
} else {
|
||||
loader_ptr = Loader::GetLoader(filename);
|
||||
loader = loader_ptr.get();
|
||||
}
|
||||
|
||||
std::string title;
|
||||
if (loader->ReadTitle(title) == Loader::ResultStatus::Success)
|
||||
|
|
|
@ -1216,7 +1216,10 @@ bool GMainWindow::LoadROM(const QString& filename) {
|
|||
case Core::System::ResultStatus::ErrorArticDisconnected:
|
||||
QMessageBox::critical(
|
||||
this, tr("Artic Base Server"),
|
||||
tr("An error has occurred whilst communicating with the Artic Base Server."));
|
||||
tr(fmt::format(
|
||||
"An error has occurred whilst communicating with the Artic Base Server.\n{}",
|
||||
system.GetStatusDetails())
|
||||
.c_str()));
|
||||
break;
|
||||
default:
|
||||
QMessageBox::critical(
|
||||
|
@ -1238,6 +1241,10 @@ bool GMainWindow::LoadROM(const QString& filename) {
|
|||
}
|
||||
|
||||
void GMainWindow::BootGame(const QString& filename) {
|
||||
if (emu_thread) {
|
||||
ShutdownGame();
|
||||
}
|
||||
|
||||
const bool is_artic = filename.startsWith(QString::fromStdString("articbase://"));
|
||||
|
||||
if (!is_artic && filename.endsWith(QStringLiteral(".cia"))) {
|
||||
|
@ -2640,10 +2647,12 @@ void GMainWindow::UpdateStatusBar() {
|
|||
const bool do_mb = results.artic_transmitted >= (1000.0 * 1000.0);
|
||||
const double value = do_mb ? (results.artic_transmitted / (1000.0 * 1000.0))
|
||||
: (results.artic_transmitted / 1000.0);
|
||||
static const std::array<std::pair<Core::PerfStats::PerfArticEventBits, QString>, 4>
|
||||
static const std::array<std::pair<Core::PerfStats::PerfArticEventBits, QString>, 5>
|
||||
perf_events = {
|
||||
std::make_pair(Core::PerfStats::PerfArticEventBits::ARTIC_SHARED_EXT_DATA,
|
||||
tr("(Accessing SharedExtData)")),
|
||||
std::make_pair(Core::PerfStats::PerfArticEventBits::ARTIC_SYSTEM_SAVE_DATA,
|
||||
tr("(Accessing SystemSaveData)")),
|
||||
std::make_pair(Core::PerfStats::PerfArticEventBits::ARTIC_BOSS_EXT_DATA,
|
||||
tr("(Accessing BossExtData)")),
|
||||
std::make_pair(Core::PerfStats::PerfArticEventBits::ARTIC_EXT_DATA,
|
||||
|
@ -2868,7 +2877,9 @@ void GMainWindow::OnCoreError(Core::System::ResultStatus result, std::string det
|
|||
error_severity_icon = QMessageBox::Icon::Warning;
|
||||
} else if (result == Core::System::ResultStatus::ErrorArticDisconnected) {
|
||||
title = tr("Artic Base Server");
|
||||
message = tr("A communication error has occurred. The game will quit.");
|
||||
message =
|
||||
tr(fmt::format("A communication error has occurred. The game will quit.\n{}", details)
|
||||
.c_str());
|
||||
error_severity_icon = QMessageBox::Icon::Critical;
|
||||
can_continue = false;
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue