set: Implement GetQuestFlag

Simply returns a true/false value indicating if the system is a kiosk system. This has been mapped to a config option for the purposes of yuzu.
This commit is contained in:
Zach Hilman 2019-06-28 18:38:47 -04:00
parent efa7d8d04b
commit f477c5dfdd
2 changed files with 10 additions and 1 deletions

View file

@ -95,6 +95,14 @@ void SET::GetAvailableLanguageCodeCount2(Kernel::HLERequestContext& ctx) {
PushResponseLanguageCode(ctx, post4_0_0_max_entries); PushResponseLanguageCode(ctx, post4_0_0_max_entries);
} }
void SET::GetQuestFlag(Kernel::HLERequestContext& ctx) {
LOG_DEBUG(Service_SET, "called");
IPC::ResponseBuilder rb{ctx, 3};
rb.Push(RESULT_SUCCESS);
rb.Push(static_cast<u32>(Settings::values.quest_flag));
}
void SET::GetLanguageCode(Kernel::HLERequestContext& ctx) { void SET::GetLanguageCode(Kernel::HLERequestContext& ctx) {
LOG_DEBUG(Service_SET, "called {}", Settings::values.language_index); LOG_DEBUG(Service_SET, "called {}", Settings::values.language_index);
@ -114,7 +122,7 @@ SET::SET() : ServiceFramework("set") {
{5, &SET::GetAvailableLanguageCodes2, "GetAvailableLanguageCodes2"}, {5, &SET::GetAvailableLanguageCodes2, "GetAvailableLanguageCodes2"},
{6, &SET::GetAvailableLanguageCodeCount2, "GetAvailableLanguageCodeCount2"}, {6, &SET::GetAvailableLanguageCodeCount2, "GetAvailableLanguageCodeCount2"},
{7, nullptr, "GetKeyCodeMap"}, {7, nullptr, "GetKeyCodeMap"},
{8, nullptr, "GetQuestFlag"}, {8, &SET::GetQuestFlag, "GetQuestFlag"},
{9, nullptr, "GetKeyCodeMap2"}, {9, nullptr, "GetKeyCodeMap2"},
}; };
// clang-format on // clang-format on

View file

@ -42,6 +42,7 @@ private:
void GetAvailableLanguageCodes2(Kernel::HLERequestContext& ctx); void GetAvailableLanguageCodes2(Kernel::HLERequestContext& ctx);
void GetAvailableLanguageCodeCount(Kernel::HLERequestContext& ctx); void GetAvailableLanguageCodeCount(Kernel::HLERequestContext& ctx);
void GetAvailableLanguageCodeCount2(Kernel::HLERequestContext& ctx); void GetAvailableLanguageCodeCount2(Kernel::HLERequestContext& ctx);
void GetQuestFlag(Kernel::HLERequestContext& ctx);
}; };
} // namespace Service::Set } // namespace Service::Set