//
// SetupMoveCommandPopup::onCustomToggleTriggerValue from 0x1403900d0 to 0x140390179 (169 bytes)
//
// 2 xrefs:
// > ??> @ 0x140772d28
// > ??> @ 0x140922f70
//
// 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:31:11 +0000
//
struct cocos2d::CCObject *__fastcall SetupMoveCommandPopup::onCustomToggleTriggerValue(
cocos2d::CCDictionary **a1,
__int64 a2)
{
struct cocos2d::CCObject *result; // rax
int v4; // ebx
struct cocos2d::CCObject *v5; // rax
__int64 v6; // rdx
__int64 v7; // rdx
result = (struct cocos2d::CCObject *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 56LL))(a2);
v4 = (int)result;
if ( (unsigned int)((_DWORD)result - 1) <= 1 )
{
if ( (int)(*((float (__fastcall **)(cocos2d::CCDictionary **, __int64))*a1 + 146))(a1, 101) == (_DWORD)result )
v4 = 0;
SetupTriggerPopup::updateValue(a1, 101);
v5 = cocos2d::CCDictionary::objectForKey(a1[97], 1);
if ( v5 )
{
LOBYTE(v6) = v4 == 1;
CCMenuItemToggler::toggle((__int64)v5, v6);
}
result = cocos2d::CCDictionary::objectForKey(a1[97], 2);
if ( result )
{
LOBYTE(v7) = v4 == 2;
return (struct cocos2d::CCObject *)CCMenuItemToggler::toggle((__int64)result, v7);
}
}
return result;
}