// // cocos2d::extension::CCControlSwitch::initWithMaskSprite from 0x18000c710 to 0x18000c91f (527 bytes) // // 5 xrefs: // > cocos2d::extension::CCControlSwitch::initWithMaskSprite @ 0x18000c64a // > cocos2d::extension::CCControlSwitch::create @ 0x18000c6c8 // > cocos2d::extension::CCControlSwitch::create @ 0x18000c990 // > @ 0x180032408 // > @ 0x18004bc60 // // 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:15:38 +0000 // // Hidden C++ exception states: #wind=1 char __fastcall cocos2d::extension::CCControlSwitch::initWithMaskSprite( cocos2d::extension::CCControlSwitch *this, struct cocos2d::CCSprite *a2, struct cocos2d::CCSprite *a3, struct cocos2d::CCSprite *a4, struct cocos2d::CCSprite *a5, struct cocos2d::CCLabelTTF *a6, struct cocos2d::CCLabelTTF *a7) { __int64 v11; // rdx __int64 v12; // rdi __int64 *v13; // rcx __int64 v14; // rdi float v15; // xmm6_4 float *v16; // rax __int64 v17; // rbx __int64 v18; // rax __int64 v19; // rbx __int64 v20; // rax __int64 v21; // rbx __int64 v22; // rax _QWORD v24[2]; // [rsp+40h] [rbp-48h] BYREF if ( !cocos2d::extension::CCControl::init(this) ) return 0; LOBYTE(v11) = 1; (*(void (__fastcall **)(cocos2d::extension::CCControlSwitch *, __int64))(*(_QWORD *)this + 920LL))(this, v11); *((_BYTE *)this + 485) = 1; v12 = sub_18001F040(0x2A8u); v24[0] = v12; cocos2d::CCSprite::CCSprite((cocos2d::CCSprite *)v12); cocos2d::CCActionTweenDelegate::CCActionTweenDelegate((cocos2d::CCActionTweenDelegate *)(v12 + 600)); *(_QWORD *)v12 = &cocos2d::extension::CCControlSwitchSprite::`vftable'; *(_QWORD *)(v12 + 320) = &cocos2d::extension::CCControlSwitchSprite::`vftable'; *(_QWORD *)(v12 + 344) = &cocos2d::extension::CCControlSwitchSprite::`vftable'; *(_QWORD *)(v12 + 600) = &cocos2d::extension::CCControlSwitchSprite::`vftable'; *(_QWORD *)(v12 + 608) = 0; *(_DWORD *)(v12 + 616) = 0; *(_QWORD *)(v12 + 624) = 0; *(_QWORD *)(v12 + 632) = 0; *(_QWORD *)(v12 + 640) = 0; *(_QWORD *)(v12 + 648) = 0; *(_QWORD *)(v12 + 656) = 0; *(_QWORD *)(v12 + 664) = 0; *(_QWORD *)(v12 + 672) = 0; *((_QWORD *)this + 59) = v12; sub_18000BC20((__int64 *)v12, (__int64)a2, a3, a4, a5, a6, a7); v13 = *((__int64 **)this + 59); v14 = *v13; v15 = *(float *)((*(__int64 (__fastcall **)(__int64 *))(*v13 + 320))(v13) + 4) * 0.5; v16 = (float *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 59) + 320LL))(*((_QWORD *)this + 59)); v17 = *((_QWORD *)this + 59); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v24, *v16 * 0.5, v15); (*(void (__fastcall **)(__int64, __int64))(v14 + 184))(v17, v18); (*(void (__fastcall **)(cocos2d::extension::CCControlSwitch *, _QWORD))(*(_QWORD *)this + 464LL))( this, *((_QWORD *)this + 59)); (*(void (__fastcall **)(cocos2d::extension::CCControlSwitch *, _QWORD))(*(_QWORD *)this + 432LL))(this, 0); v19 = *(_QWORD *)this; cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v24, 0.5, 0.5); (*(void (__fastcall **)(cocos2d::extension::CCControlSwitch *, __int64))(v19 + 288))(this, v20); v21 = *(_QWORD *)this; v22 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 59) + 320LL))(*((_QWORD *)this + 59)); (*(void (__fastcall **)(cocos2d::extension::CCControlSwitch *, __int64))(v21 + 312))(this, v22); return 1; }