From 04d9c27120662e2e885bc70b50123ffd982a5a54 Mon Sep 17 00:00:00 2001 From: Morph <39850852+Morph1984@users.noreply.github.com> Date: Fri, 23 Apr 2021 22:46:25 -0400 Subject: [PATCH] ICommonStateGetter: Stub SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled - Used by Pixel Game Maker Series Werewolf Princess Kaguya --- src/core/hle/service/am/am.cpp | 10 +++++++++- src/core/hle/service/am/am.h | 1 + 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/core/hle/service/am/am.cpp b/src/core/hle/service/am/am.cpp index 4c8216b47..58c7f2930 100644 --- a/src/core/hle/service/am/am.cpp +++ b/src/core/hle/service/am/am.cpp @@ -687,7 +687,7 @@ ICommonStateGetter::ICommonStateGetter(Core::System& system_, {501, nullptr, "SuppressDisablingSleepTemporarily"}, {502, nullptr, "IsSleepEnabled"}, {503, nullptr, "IsDisablingSleepSuppressed"}, - {900, nullptr, "SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled"}, + {900, &ICommonStateGetter::SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled, "SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled"}, }; // clang-format on @@ -817,6 +817,14 @@ void ICommonStateGetter::SetCpuBoostMode(Kernel::HLERequestContext& ctx) { apm_sys->SetCpuBoostMode(ctx); } +void ICommonStateGetter::SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled( + Kernel::HLERequestContext& ctx) { + LOG_WARNING(Service_AM, "(STUBBED) called"); + + IPC::ResponseBuilder rb{ctx, 2}; + rb.Push(RESULT_SUCCESS); +} + IStorageImpl::~IStorageImpl() = default; class StorageDataImpl final : public IStorageImpl { diff --git a/src/core/hle/service/am/am.h b/src/core/hle/service/am/am.h index 756434716..5d302e155 100644 --- a/src/core/hle/service/am/am.h +++ b/src/core/hle/service/am/am.h @@ -196,6 +196,7 @@ private: void EndVrModeEx(Kernel::HLERequestContext& ctx); void GetDefaultDisplayResolution(Kernel::HLERequestContext& ctx); void SetCpuBoostMode(Kernel::HLERequestContext& ctx); + void SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled(Kernel::HLERequestContext& ctx); std::shared_ptr msg_queue; bool vr_mode_state{};