//
// ShareLevelSettingsLayer::updateSettingsState from 0x1406337d0 to 0x1406338a1 (209 bytes)
//
// 3 xrefs:
// > ShareLevelSettingsLayer::init @ 0x140633414
// > ShareLevelSettingsLayer::onUnlisted @ 0x1406337aa
// > ??> @ 0x140930b90
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:35:29 +0000
//
__int64 __fastcall ShareLevelSettingsLayer::updateSettingsState(_QWORD *a1)
{
unsigned __int8 v2; // bp
__int64 v3; // rbx
void *v4; // rdi
__int64 v5; // rax
__int64 v6; // rax
v2 = *(_BYTE *)(a1[85] + 688LL);
if ( !v2 )
CCMenuItemToggler::toggle(a1[86], 0);
(*(void (__fastcall **)(_QWORD, _QWORD))(*(_QWORD *)a1[86] + 936LL))(a1[86], v2);
v3 = a1[86];
v4 = &unk_1407046C8;
if ( v2 )
v4 = &unk_1407046CC;
v5 = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(v3 + 376) + 952LL))(*(_QWORD *)(v3 + 376));
(**(void (__fastcall ***)(__int64, void *))(v5 + 320))(v5 + 320, v4);
v6 = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(v3 + 384) + 952LL))(*(_QWORD *)(v3 + 384));
(**(void (__fastcall ***)(__int64, void *))(v6 + 320))(v6 + 320, v4);
return (**(__int64 (__fastcall ***)(__int64, void *))(a1[87] + 368LL))(a1[87] + 368LL, v4);
}