{"type": "func", "start": 6442504608, "end": 6442504929, "name": "cocos2d::extension::CCControlSwitch::ccTouchEnded", "pseudocode": "// \n// cocos2d::extension::CCControlSwitch::ccTouchEnded from 0x18000d1a0 to 0x18000d2e1 (321 bytes)\n// \n// 4 xrefs:\n// > <???> @ 0x180026660\n// > <???> @ 0x180026668\n// > <???> @ 0x18002fdf8\n// > <???> @ 0x180049de0\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\n// Alternative name is '?ccTouchCancelled@CCControlSwitch@extension@cocos2d@@UEAAXPEAVCCTouch@3@PEAVCCEvent@3@@Z'\nvoid __fastcall cocos2d::extension::CCControlSwitch::ccTouchEnded(\n        cocos2d::extension::CCControlSwitch *this,\n        struct cocos2d::CCTouch *a2,\n        struct cocos2d::CCEvent *a3)\n{\n  char *v4; // rbx\n  __int64 v5; // rax\n  void (__fastcall ***v6)(_QWORD, void *); // rcx\n  float *v7; // rax\n  float *v8; // rcx\n  float v9; // xmm3_4\n  float v10; // xmm2_4\n  char v11; // cl\n  float *v12; // rax\n  struct cocos2d::CCAction *v13; // rax\n  float v14; // [rsp+30h] [rbp+8h] BYREF\n  char v15; // [rsp+48h] [rbp+20h] BYREF\n\n  cocos2d::CCTouch::getLocation(a2);\n  v4 = (char *)this - 320;\n  v5 = cocos2d::CCNode::convertToNodeSpace((char *)this - 320, &v15, &v14);\n  cocos2d::CCPoint::operator=(&v14, v5);\n  v6 = (void (__fastcall ***)(_QWORD, void *))(*(_QWORD *)(*((_QWORD *)this + 19) + 656LL) + 320LL);\n  (**v6)(v6, &unk_1800234B8);\n  if ( *((_BYTE *)this + 164) )\n  {\n    v7 = (float *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 19) + 304LL))(*((_QWORD *)this + 19));\n    v8 = *((float **)v4 + 59);\n    LOBYTE(v7) = (float)(*v7 * 0.5) <= v14;\n    v4[485] = (char)v7;\n    if ( (_BYTE)v7 )\n      v9 = v8[153];\n    else\n      v9 = v8[154];\n    v10 = v8[152];\n  }\n  else\n  {\n    v11 = *((_BYTE *)this + 165);\n    v4[485] = v11 == 0;\n    v12 = *((float **)v4 + 59);\n    if ( v11 )\n      v9 = v12[154];\n    else\n      v9 = v12[153];\n    v10 = v12[152];\n  }\n  v13 = cocos2d::CCActionTween::create(0.2, \"sliderXPosition\", v10, v9);\n  cocos2d::CCNode::runAction(*((cocos2d::CCNode **)v4 + 59), v13);\n  (*(void (__fastcall **)(char *, __int64))(*(_QWORD *)v4 + 1072LL))((char *)this - 320, 256);\n}", "assembly": "; \n; cocos2d::extension::CCControlSwitch::ccTouchEnded from 0x18000d1a0 to 0x18000d2e1 (321 bytes)\n; \n; 4 xrefs:\n; > <???> @ 0x180026660\n; > <???> @ 0x180026668\n; > <???> @ 0x18002fdf8\n; > <???> @ 0x180049de0\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\nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x18000d1a0\npush    rdi                                                            ; +0x5, 0x18000d1a5\nsub     rsp, 20h                                                       ; +0x6, 0x18000d1a6\nmov     rax, rdx                                                       ; +0xa, 0x18000d1aa\nmov     rdi, rcx                                                       ; +0xd, 0x18000d1ad\nmov     rcx, rax                                                       ; +0x10, 0x18000d1b0\nlea     rdx, [rsp+28h+arg_0]                                           ; +0x13, 0x18000d1b3\ncall    cs:?getLocation@CCTouch@cocos2d@@QEBA?AVCCPoint@2@XZ; cocos2d::CCTouch::getLocation(void) ; +0x18, 0x18000d1b8\nlea     rbx, [rdi-140h]                                                ; +0x1e, 0x18000d1be\nmov     rcx, rbx                                                       ; +0x25, 0x18000d1c5\nlea     r8, [rsp+28h+arg_0]                                            ; +0x28, 0x18000d1c8\nlea     rdx, [rsp+28h+arg_18]                                          ; +0x2d, 0x18000d1cd\ncall    cs:?convertToNodeSpace@CCNode@cocos2d@@QEAA?AVCCPoint@2@AEBV32@@Z; cocos2d::CCNode::convertToNodeSpace(cocos2d::CCPoint const &) ; +0x32, 0x18000d1d2\nmov     rdx, rax                                                       ; +0x38, 0x18000d1d8\nlea     rcx, [rsp+28h+arg_0]                                           ; +0x3b, 0x18000d1db\ncall    cs:??4CCPoint@cocos2d@@QEAAAEAV01@AEBV01@@Z; cocos2d::CCPoint::operator=(cocos2d::CCPoint const &) ; +0x40, 0x18000d1e0\nmov     rax, [rdi+98h]                                                 ; +0x46, 0x18000d1e6\nlea     rdx, unk_1800234B8                                             ; +0x4d, 0x18000d1ed\nmov     rcx, [rax+290h]                                                ; +0x54, 0x18000d1f4\nadd     rcx, 140h                                                      ; +0x5b, 0x18000d1fb\nmov     rax, [rcx]                                                     ; +0x62, 0x18000d202\ncall    qword ptr [rax]                                                ; +0x65, 0x18000d205\ncmp     byte ptr [rdi+0A4h], 0                                         ; +0x67, 0x18000d207\njz      short loc_18000D269                                            ; +0x6e, 0x18000d20e\nmov     rcx, [rdi+98h]                                                 ; +0x70, 0x18000d210\nmov     rax, [rcx]                                                     ; +0x77, 0x18000d217\ncall    qword ptr [rax+130h]                                           ; +0x7a, 0x18000d21a\nmov     rcx, [rbx+1D8h]                                                ; +0x80, 0x18000d220\nmovss   xmm0, dword ptr [rax]                                          ; +0x87, 0x18000d227\nmulss   xmm0, cs:dword_180029510                                       ; +0x8b, 0x18000d22b\ncomiss  xmm0, [rsp+28h+arg_0]                                          ; +0x93, 0x18000d233\nsetbe   al                                                             ; +0x98, 0x18000d238\nmov     [rbx+1E5h], al                                                 ; +0x9b, 0x18000d23b\ntest    al, al                                                         ; +0xa1, 0x18000d241\njz      short loc_18000D257                                            ; +0xa3, 0x18000d243\nmovss   xmm3, dword ptr [rcx+264h]                                     ; +0xa5, 0x18000d245\nmovss   xmm2, dword ptr [rcx+260h]                                     ; +0xad, 0x18000d24d\njmp     short loc_18000D2A0                                            ; +0xb5, 0x18000d255\nmovss   xmm3, dword ptr [rcx+268h]                                     ; +0xb7, 0x18000d257\nmovss   xmm2, dword ptr [rcx+260h]                                     ; +0xbf, 0x18000d25f\njmp     short loc_18000D2A0                                            ; +0xc7, 0x18000d267\nmovzx   ecx, byte ptr [rdi+0A5h]                                       ; +0xc9, 0x18000d269\ntest    cl, cl                                                         ; +0xd0, 0x18000d270\nsetz    al                                                             ; +0xd2, 0x18000d272\nmov     [rbx+1E5h], al                                                 ; +0xd5, 0x18000d275\nmov     rax, [rbx+1D8h]                                                ; +0xdb, 0x18000d27b\ntest    cl, cl                                                         ; +0xe2, 0x18000d282\njnz     short loc_18000D290                                            ; +0xe4, 0x18000d284\nmovss   xmm3, dword ptr [rax+264h]                                     ; +0xe6, 0x18000d286\njmp     short loc_18000D298                                            ; +0xee, 0x18000d28e\nmovss   xmm3, dword ptr [rax+268h]                                     ; +0xf0, 0x18000d290\nmovss   xmm2, dword ptr [rax+260h]                                     ; +0xf8, 0x18000d298\nmovss   xmm0, cs:dword_180029508                                       ; +0x100, 0x18000d2a0\nlea     rdx, aSliderxpositio; \"sliderXPosition\"                        ; +0x108, 0x18000d2a8\ncall    cs:?create@CCActionTween@cocos2d@@SAPEAV12@MPEBDMM@Z; cocos2d::CCActionTween::create(float,char const *,float,float) ; +0x10f, 0x18000d2af\nmov     rcx, [rbx+1D8h]                                                ; +0x115, 0x18000d2b5\nmov     rdx, rax                                                       ; +0x11c, 0x18000d2bc\ncall    cs:?runAction@CCNode@cocos2d@@QEAAPEAVCCAction@2@PEAV32@@Z; cocos2d::CCNode::runAction(cocos2d::CCAction *) ; +0x11f, 0x18000d2bf\nmov     rax, [rbx]                                                     ; +0x125, 0x18000d2c5\nmov     edx, 100h                                                      ; +0x128, 0x18000d2c8\nmov     rcx, rbx                                                       ; +0x12d, 0x18000d2cd\ncall    qword ptr [rax+430h]                                           ; +0x130, 0x18000d2d0\nmov     rbx, [rsp+28h+arg_8]                                           ; +0x136, 0x18000d2d6\nadd     rsp, 20h                                                       ; +0x13b, 0x18000d2db\npop     rdi                                                            ; +0x13f, 0x18000d2df\nretn                                                                   ; +0x140, 0x18000d2e0", "xrefs": ["<???> @ 0x180026660", "<???> @ 0x180026668", "<???> @ 0x18002fdf8", "<???> @ 0x180049de0"], "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"}