Decompile fn_06324 (SetOption)

Batch #13993 by eAthena: 0 byte-identical, 1 confirmed by peer review.

- fn_06324 SetOption: logic confirmed by peer review

Peer-reviewed-by: Yommy, KWDev, aDw
Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
This commit is contained in:
ragnarok-clanker 2026-11-07 04:10:23 +00:00
commit 2f05afd829

View file

@ -713,16 +713,18 @@ void GameSettings::ToggleOption(int id) {
// OFFSET: 0x006C29A0
// FUNCTION: fn_06324
__declspec(noinline) int SetOption(const char* name, unsigned char value) {
if (!name || name[0] == '\0') {
if (IsNullOrEmpty(name)) {
return 3;
}
int optionId = 3;
std::string strings[3];
g_session.GetTalkType(name, &optionId, strings);
if (optionId != 3) {
g_serviceOptions.values[static_cast<std::uint32_t>(optionId)] = value;
if (optionId == 3) {
return 3;
}
g_serviceOptions.values[static_cast<std::uint32_t>(optionId)] = value;
return optionId;
}