// // cocos2d::CCMenuItemToggle::setSelectedIndex from 0x18005dbc0 to 0x18005dcbb (251 bytes) // // 3 xrefs: // > @ 0x1800ff4a8 // > @ 0x18014cf68 // > @ 0x1801bd21c // // 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:21:49 +0000 // void __fastcall cocos2d::CCMenuItemToggle::setSelectedIndex(cocos2d::CCMenuItemToggle *this, int a2) { __int64 v4; // rax __int64 v5; // rax struct cocos2d::CCString *v6; // rdi _DWORD *v7; // rax __int64 v8; // rbx float *v9; // rax float v10; // [rsp+30h] [rbp+8h] BYREF float v11; // [rsp+34h] [rbp+Ch] float v12; // [rsp+40h] [rbp+18h] BYREF if ( a2 != *((_DWORD *)this + 94) && (unsigned int)cocos2d::CCArray::count(*((cocos2d::CCArray **)this + 48)) ) { v4 = *(_QWORD *)this; *((_DWORD *)this + 94) = a2; v5 = (*(__int64 (__fastcall **)(cocos2d::CCMenuItemToggle *, __int64))(v4 + 472))(this, 3233828865LL); if ( v5 ) (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v5 + 520LL))(v5, 0); v6 = cocos2d::CCArray::stringAtIndex(*((cocos2d::CCArray **)this + 48), *((_DWORD *)this + 94)); (*(void (__fastcall **)(cocos2d::CCMenuItemToggle *, struct cocos2d::CCString *, _QWORD, __int64))(*(_QWORD *)this + 448LL))( this, v6, 0, 3233828865LL); v7 = (_DWORD *)(*(__int64 (__fastcall **)(struct cocos2d::CCString *))(*(_QWORD *)v6 + 320LL))(v6); cocos2d::cc_timeval::operator=(&v10, v7); (*(void (__fastcall **)(cocos2d::CCMenuItemToggle *, float *))(*(_QWORD *)this + 312LL))(this, &v10); v8 = *(_QWORD *)v6; v9 = kmVec2Fill(&v12, v10 * 0.5, v11 * 0.5); (*(void (__fastcall **)(struct cocos2d::CCString *, float *))(v8 + 184))(v6, v9); } }