{"type": "func", "start": 6442503920, "end": 6442504106, "name": "cocos2d::extension::CCControlSwitch::setOn", "pseudocode": "// \n// cocos2d::extension::CCControlSwitch::setOn from 0x18000cef0 to 0x18000cfaa (186 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x18002fdf8\n// > <???> @ 0x180049dbc\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid __fastcall cocos2d::extension::CCControlSwitch::setOn(cocos2d::extension::CCControlSwitch *this, char a2, char a3)\n{\n  float *v4; // rax\n  float v5; // xmm3_4\n  struct cocos2d::CCAction *v6; // rax\n  float *v7; // rcx\n  float v8; // xmm1_4\n  float v9; // xmm0_4\n\n  *((_BYTE *)this + 485) = a2;\n  if ( a3 )\n  {\n    v4 = *((float **)this + 59);\n    if ( a2 )\n      v5 = v4[153];\n    else\n      v5 = v4[154];\n    v6 = cocos2d::CCActionTween::create(0.2, \"sliderXPosition\", v4[152], v5);\n    cocos2d::CCNode::runAction(*((cocos2d::CCNode **)this + 59), v6);\n  }\n  else\n  {\n    v7 = *((float **)this + 59);\n    if ( a2 )\n      v8 = v7[153];\n    else\n      v8 = v7[154];\n    v9 = v7[154];\n    if ( v9 < v8 )\n      v9 = fminf(v7[153], v8);\n    v7[152] = v9;\n    sub_18000C670((__int64)v7);\n  }\n  (*(void (__fastcall **)(cocos2d::extension::CCControlSwitch *, __int64))(*(_QWORD *)this + 1072LL))(this, 256);\n}", "assembly": "; \n; cocos2d::extension::CCControlSwitch::setOn from 0x18000cef0 to 0x18000cfaa (186 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x18002fdf8\n; > <???> @ 0x180049dbc\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\npush    rbx                                                            ; +0x0, 0x18000cef0\nsub     rsp, 20h                                                       ; +0x2, 0x18000cef2\nmov     [rcx+1E5h], dl                                                 ; +0x6, 0x18000cef6\nmov     rbx, rcx                                                       ; +0xc, 0x18000cefc\ntest    r8b, r8b                                                       ; +0xf, 0x18000ceff\njz      short loc_18000CF50                                            ; +0x12, 0x18000cf02\nmov     rax, [rcx+1D8h]                                                ; +0x14, 0x18000cf04\ntest    dl, dl                                                         ; +0x1b, 0x18000cf0b\njz      short loc_18000CF19                                            ; +0x1d, 0x18000cf0d\nmovss   xmm3, dword ptr [rax+264h]                                     ; +0x1f, 0x18000cf0f\njmp     short loc_18000CF21                                            ; +0x27, 0x18000cf17\nmovss   xmm3, dword ptr [rax+268h]                                     ; +0x29, 0x18000cf19\nmovss   xmm2, dword ptr [rax+260h]                                     ; +0x31, 0x18000cf21\nlea     rdx, aSliderxpositio; \"sliderXPosition\"                        ; +0x39, 0x18000cf29\nmovss   xmm0, cs:dword_180029508                                       ; +0x40, 0x18000cf30\ncall    cs:?create@CCActionTween@cocos2d@@SAPEAV12@MPEBDMM@Z; cocos2d::CCActionTween::create(float,char const *,float,float) ; +0x48, 0x18000cf38\nmov     rcx, [rbx+1D8h]                                                ; +0x4e, 0x18000cf3e\nmov     rdx, rax                                                       ; +0x55, 0x18000cf45\ncall    cs:?runAction@CCNode@cocos2d@@QEAAPEAVCCAction@2@PEAV32@@Z; cocos2d::CCNode::runAction(cocos2d::CCAction *) ; +0x58, 0x18000cf48\njmp     short loc_18000CF93                                            ; +0x5e, 0x18000cf4e\nmov     rcx, [rcx+1D8h]                                                ; +0x60, 0x18000cf50\ntest    dl, dl                                                         ; +0x67, 0x18000cf57\njz      short loc_18000CF65                                            ; +0x69, 0x18000cf59\nmovss   xmm1, dword ptr [rcx+264h]                                     ; +0x6b, 0x18000cf5b\njmp     short loc_18000CF6D                                            ; +0x73, 0x18000cf63\nmovss   xmm1, dword ptr [rcx+268h]                                     ; +0x75, 0x18000cf65\nmovss   xmm0, dword ptr [rcx+268h]                                     ; +0x7d, 0x18000cf6d\ncomiss  xmm0, xmm1                                                     ; +0x85, 0x18000cf75\njnb     short loc_18000CF86                                            ; +0x88, 0x18000cf78\nmovss   xmm0, dword ptr [rcx+264h]                                     ; +0x8a, 0x18000cf7a\nminss   xmm0, xmm1                                                     ; +0x92, 0x18000cf82\nmovss   dword ptr [rcx+260h], xmm0                                     ; +0x96, 0x18000cf86\ncall    sub_18000C670                                                  ; +0x9e, 0x18000cf8e\nmov     rax, [rbx]                                                     ; +0xa3, 0x18000cf93\nmov     edx, 100h                                                      ; +0xa6, 0x18000cf96\nmov     rcx, rbx                                                       ; +0xab, 0x18000cf9b\nadd     rsp, 20h                                                       ; +0xae, 0x18000cf9e\npop     rbx                                                            ; +0xb2, 0x18000cfa2\njmp     qword ptr [rax+430h]                                           ; +0xb3, 0x18000cfa3", "xrefs": ["<???> @ 0x18002fdf8", "<???> @ 0x180049dbc"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}