{"type": "func", "start": 6442502960, "end": 6442503205, "name": "cocos2d::extension::CCControlSwitch::ccTouchBegan", "pseudocode": "// \n// cocos2d::extension::CCControlSwitch::ccTouchBegan from 0x18000cb30 to 0x18000cc25 (245 bytes)\n// \n// 3 xrefs:\n// > <???> @ 0x180028c68\n// > <???> @ 0x180032408\n// > <???> @ 0x18004bca8\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 12:15:38 +0000\n// \n\nchar __fastcall cocos2d::extension::CCControlSwitch::ccTouchBegan(\n        cocos2d::extension::CCControlSwitch *this,\n        struct cocos2d::CCTouch *a2,\n        struct cocos2d::CCEvent *a3)\n{\n  char *v3; // rbx\n  __int64 v6; // rax\n  __int64 v7; // rax\n  float v9; // [rsp+30h] [rbp+8h] BYREF\n  char v10; // [rsp+48h] [rbp+20h] BYREF\n\n  v3 = (char *)this - 320;\n  if ( !(*(unsigned __int8 (__fastcall **)(char *, struct cocos2d::CCTouch *, struct cocos2d::CCEvent *))(*((_QWORD *)this - 40) + 1120LL))(\n          (char *)this - 320,\n          a2,\n          a3)\n    || !(*(unsigned __int8 (__fastcall **)(char *))(*(_QWORD *)v3 + 1040LL))(v3)\n    || !(*(unsigned __int8 (__fastcall **)(char *))(*(_QWORD *)v3 + 344LL))(v3) )\n  {\n    return 0;\n  }\n  *((_BYTE *)this + 164) = 0;\n  cocos2d::CCTouch::getLocation(a2);\n  v6 = cocos2d::CCNode::convertToNodeSpace(v3, &v10, &v9);\n  cocos2d::CCPoint::operator=(&v9, v6);\n  v7 = *((_QWORD *)this + 19);\n  *((float *)this + 40) = v9 - *(float *)(v7 + 608);\n  (**(void (__fastcall ***)(__int64, void *))(*(_QWORD *)(v7 + 656) + 320LL))(\n    *(_QWORD *)(v7 + 656) + 320LL,\n    &unk_180025A2C);\n  sub_18000C1C0(*((_QWORD *)this + 19));\n  return 1;\n}", "assembly": "; \n; cocos2d::extension::CCControlSwitch::ccTouchBegan from 0x18000cb30 to 0x18000cc25 (245 bytes)\n; \n; 3 xrefs:\n; > <???> @ 0x180028c68\n; > <???> @ 0x180032408\n; > <???> @ 0x18004bca8\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 12:15:38 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x18000cb30\nmov     [rsp+arg_10], rsi                                              ; +0x5, 0x18000cb35\npush    rdi                                                            ; +0xa, 0x18000cb3a\nsub     rsp, 20h                                                       ; +0xb, 0x18000cb3b\nlea     rbx, [rcx-140h]                                                ; +0xf, 0x18000cb3f\nmov     rdi, rcx                                                       ; +0x16, 0x18000cb46\nmov     rax, [rbx]                                                     ; +0x19, 0x18000cb49\nmov     rcx, rbx                                                       ; +0x1c, 0x18000cb4c\nmov     rsi, rdx                                                       ; +0x1f, 0x18000cb4f\ncall    qword ptr [rax+460h]                                           ; +0x22, 0x18000cb52\ntest    al, al                                                         ; +0x28, 0x18000cb58\njz      loc_18000CC13                                                  ; +0x2a, 0x18000cb5a\nmov     rax, [rbx]                                                     ; +0x30, 0x18000cb60\nmov     rcx, rbx                                                       ; +0x33, 0x18000cb63\ncall    qword ptr [rax+410h]                                           ; +0x36, 0x18000cb66\ntest    al, al                                                         ; +0x3c, 0x18000cb6c\njz      loc_18000CC13                                                  ; +0x3e, 0x18000cb6e\nmov     rax, [rbx]                                                     ; +0x44, 0x18000cb74\nmov     rcx, rbx                                                       ; +0x47, 0x18000cb77\ncall    qword ptr [rax+158h]                                           ; +0x4a, 0x18000cb7a\ntest    al, al                                                         ; +0x50, 0x18000cb80\njz      loc_18000CC13                                                  ; +0x52, 0x18000cb82\nlea     rdx, [rsp+28h+arg_0]                                           ; +0x58, 0x18000cb88\nmov     byte ptr [rdi+0A4h], 0                                         ; +0x5d, 0x18000cb8d\nmov     rcx, rsi                                                       ; +0x64, 0x18000cb94\ncall    cs:?getLocation@CCTouch@cocos2d@@QEBA?AVCCPoint@2@XZ; cocos2d::CCTouch::getLocation(void) ; +0x67, 0x18000cb97\nlea     r8, [rsp+28h+arg_0]                                            ; +0x6d, 0x18000cb9d\nmov     rcx, rbx                                                       ; +0x72, 0x18000cba2\nlea     rdx, [rsp+28h+arg_18]                                          ; +0x75, 0x18000cba5\ncall    cs:?convertToNodeSpace@CCNode@cocos2d@@QEAA?AVCCPoint@2@AEBV32@@Z; cocos2d::CCNode::convertToNodeSpace(cocos2d::CCPoint const &) ; +0x7a, 0x18000cbaa\nmov     rdx, rax                                                       ; +0x80, 0x18000cbb0\nlea     rcx, [rsp+28h+arg_0]                                           ; +0x83, 0x18000cbb3\ncall    cs:??4CCPoint@cocos2d@@QEAAAEAV01@AEBV01@@Z; cocos2d::CCPoint::operator=(cocos2d::CCPoint const &) ; +0x88, 0x18000cbb8\nmov     rax, [rdi+98h]                                                 ; +0x8e, 0x18000cbbe\nlea     rdx, unk_180025A2C                                             ; +0x95, 0x18000cbc5\nmovss   xmm0, [rsp+28h+arg_0]                                          ; +0x9c, 0x18000cbcc\nsubss   xmm0, dword ptr [rax+260h]                                     ; +0xa2, 0x18000cbd2\nmovss   dword ptr [rdi+0A0h], xmm0                                     ; +0xaa, 0x18000cbda\nmov     rcx, [rax+290h]                                                ; +0xb2, 0x18000cbe2\nadd     rcx, 140h                                                      ; +0xb9, 0x18000cbe9\nmov     rax, [rcx]                                                     ; +0xc0, 0x18000cbf0\ncall    qword ptr [rax]                                                ; +0xc3, 0x18000cbf3\nmov     rcx, [rdi+98h]                                                 ; +0xc5, 0x18000cbf5\ncall    sub_18000C1C0                                                  ; +0xcc, 0x18000cbfc\nmov     al, 1                                                          ; +0xd1, 0x18000cc01\nmov     rbx, [rsp+28h+arg_8]                                           ; +0xd3, 0x18000cc03\nmov     rsi, [rsp+28h+arg_10]                                          ; +0xd8, 0x18000cc08\nadd     rsp, 20h                                                       ; +0xdd, 0x18000cc0d\npop     rdi                                                            ; +0xe1, 0x18000cc11\nretn                                                                   ; +0xe2, 0x18000cc12\nmov     rbx, [rsp+28h+arg_8]                                           ; +0xe3, 0x18000cc13\nxor     al, al                                                         ; +0xe8, 0x18000cc18\nmov     rsi, [rsp+28h+arg_10]                                          ; +0xea, 0x18000cc1a\nadd     rsp, 20h                                                       ; +0xef, 0x18000cc1f\npop     rdi                                                            ; +0xf3, 0x18000cc23\nretn                                                                   ; +0xf4, 0x18000cc24", "xrefs": ["<???> @ 0x180028c68", "<???> @ 0x180032408", "<???> @ 0x18004bca8"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}