//
// SetupTriggerPopup::toggleDisableButtons from 0x10021fd00 to 0x10021fdfc (252 bytes)
//
// 4 xrefs:
// > SetupShaderEffectPopup::setupShockWave @ 0x1002b4269
// > SetupShaderEffectPopup::setupShockLine @ 0x1002b55c9
// > SetupShaderEffectPopup::valueDidChange @ 0x1002bd35e
// > SetupShaderEffectPopup::toggleGroup @ 0x1002bd687
//
// 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 12:27:03 +0000
//
_QWORD *__fastcall SetupTriggerPopup::toggleDisableButtons(__int64 a1, char a2)
{
_QWORD *result; // rax
_QWORD *v3; // r12
__int64 v4; // r14
__int64 v5; // r15
__int64 v6; // rsi
__int64 v7; // rax
unsigned __int8 v8; // al
unsigned int v9; // r15d
__int64 v10; // rbx
result = *(_QWORD **)(a1 + 784);
if ( result )
{
result = (_QWORD *)result[7];
if ( result )
{
v3 = (_QWORD *)result[36];
if ( a2 )
{
while ( 1 )
{
v4 = result[33];
v5 = *(_QWORD *)(a1 + 760);
v6 = (*(int (__fastcall **)(__int64))(*(_QWORD *)v4 + 64LL))(v4);
v7 = cocos2d::CCDictionary::objectForKey_1(v5);
v8 = v7 ? (*(unsigned __int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v7 + 352LL))(v7, v6) : 1;
v9 = v8;
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v4 + 344LL))(v4, v8);
result = (_QWORD *)(*(__int64 (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v4 + 1056LL))(v4, v9);
if ( !v3 )
break;
result = v3;
v3 = (_QWORD *)v3[36];
}
}
else
{
v10 = result[33];
while ( 1 )
{
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v10 + 344LL))(v10, 0);
result = (_QWORD *)(*(__int64 (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v10 + 1056LL))(v10, 0);
if ( !v3 )
break;
v10 = v3[33];
v3 = (_QWORD *)v3[36];
}
}
}
}
return result;
}