{"type": "func", "start": 4299274592, "end": 4299274982, "name": "CCScrollLayerExt::ccTouchBegan", "pseudocode": "// \n// CCScrollLayerExt::ccTouchBegan from 0x10041b960 to 0x10041bae6 (390 bytes)\n// \n// 3 xrefs:\n// > sub_10041BAF0 @ 0x10041bafc\n// > TableView::ccTouchBegan @ 0x1006ff465\n// > <???> @ 0x100b3fc78\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:30:13 +0000\n// \n\nchar __fastcall CCScrollLayerExt::ccTouchBegan(__int64 a1, __int64 a2)\n{\n  __int64 v3; // rax\n  const void *v4; // r14\n  void *v5; // rax\n  __int64 v6; // rsi\n  __int64 v7; // rax\n  _QWORD *v8; // rax\n  _QWORD *v9; // rax\n  __int64 v10; // [rsp-50h] [rbp-50h] BYREF\n  __int64 v11; // [rsp-48h] [rbp-48h]\n  _OWORD v12[4]; // [rsp-40h] [rbp-40h] BYREF\n\n  if ( *(_BYTE *)(a1 + 501) )\n    return 0;\n  v11 = a2;\n  cocos2d::CCTouch::getLocation((__int64)v12, a2);\n  v3 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 512LL))(a1);\n  if ( v3 )\n  {\n    v4 = (const void *)v3;\n    while ( 1 )\n    {\n      v5 = __dynamic_cast(\n             v4,\n             (const struct __class_type_info *)&`typeinfo for'cocos2d::CCNode,\n             (const struct __class_type_info *)&`typeinfo for'cocos2d::CCTouchClipper,\n             -2);\n      if ( v5 )\n      {\n        if ( !(*(unsigned __int8 (__fastcall **)(void *, _OWORD *))(*(_QWORD *)v5 + 16LL))(v5, v12) )\n          break;\n      }\n      v4 = (const void *)(*(__int64 (__fastcall **)(const void *))(*(_QWORD *)v4 + 512LL))(v4);\n      if ( !v4 )\n        goto LABEL_9;\n    }\n  }\n  else\n  {\nLABEL_9:\n    v6 = v11;\n    *(_QWORD *)(a1 + 416) = v11;\n    cocos2d::CCTouch::getLocationInView((__int64)&v10, v6);\n    v7 = cocos2d::CCDirector::sharedDirector(&v10, v6);\n    cocos2d::CCDirector::convertToGL(v12, v7, &v10);\n    v8 = sub_100278300((_QWORD *)(a1 + 424), v12);\n    sub_100278300((_QWORD *)(a1 + 432), v8);\n    cocos2d::CCNode::convertToNodeSpace((double *)v12, a1, (unsigned int *)(a1 + 424));\n    sub_100278300(&v10, v12);\n    sub_1002787A0(v12);\n    sub_100278300(v12, &qword_100BE38C8);\n    v9 = (_QWORD *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 328LL))(a1);\n    sub_100278660((_QWORD *)v12 + 1, v9);\n    if ( sub_100278940((float *)v12, (float *)&v10) )\n    {\n      cocos2d::CCNode::stopAllActions(*(_QWORD *)(a1 + 488));\n      cocos2d::CCTime::gettimeofdayCocos2d((timeval *)(a1 + 440));\n      *(_BYTE *)(a1 + 456) = 1;\n      return *(_BYTE *)(a1 + 501) ^ 1;\n    }\n  }\n  return 0;\n}", "assembly": "; \n; CCScrollLayerExt::ccTouchBegan from 0x10041b960 to 0x10041bae6 (390 bytes)\n; \n; 3 xrefs:\n; > sub_10041BAF0 @ 0x10041bafc\n; > TableView::ccTouchBegan @ 0x1006ff465\n; > <???> @ 0x100b3fc78\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:30:13 +0000\n; \ncmp     byte ptr [rdi+1F5h], 0                                         ; +0x0, 0x10041b960\njz      short loc_10041B96C                                            ; +0x7, 0x10041b967\nxor     eax, eax                                                       ; +0x9, 0x10041b969\nretn                                                                   ; +0xb, 0x10041b96b\npush    rbp                                                            ; +0xc, 0x10041b96c\nmov     rbp, rsp                                                       ; +0xd, 0x10041b96d\npush    r15                                                            ; +0x10, 0x10041b970\npush    r14                                                            ; +0x12, 0x10041b972\npush    r13                                                            ; +0x14, 0x10041b974\npush    r12                                                            ; +0x16, 0x10041b976\npush    rbx                                                            ; +0x18, 0x10041b978\nsub     rsp, 28h                                                       ; +0x19, 0x10041b979\nmov     rbx, rdi                                                       ; +0x1d, 0x10041b97d\nlea     rdi, [rbp-38h]                                                 ; +0x20, 0x10041b980\nmov     [rbp-40h], rsi                                                 ; +0x24, 0x10041b984\ncall    cocos2d__CCTouch__getLocation                                  ; +0x28, 0x10041b988\nmov     rax, [rbx]                                                     ; +0x2d, 0x10041b98d\nmov     rdi, rbx                                                       ; +0x30, 0x10041b990\ncall    qword ptr [rax+200h]                                           ; +0x33, 0x10041b993\ntest    rax, rax                                                       ; +0x39, 0x10041b999\njz      short loc_10041BA03                                            ; +0x3c, 0x10041b99c\nmov     r14, rax                                                       ; +0x3e, 0x10041b99e\nlea     r15, _ZTIN7cocos2d6CCNodeE; `typeinfo for'cocos2d::CCNode      ; +0x41, 0x10041b9a1\nmov     r12, cs:__ZTIN7cocos2d14CCTouchClipperE_ptr                    ; +0x48, 0x10041b9a8\nlea     r13, [rbp-38h]                                                 ; +0x4f, 0x10041b9af\njmp     short loc_10041B9D4                                            ; +0x53, 0x10041b9b3\nalign 20h                                                              ; +0x55, 0x10041b9b5\nmov     rax, [r14]                                                     ; +0x60, 0x10041b9c0\nmov     rdi, r14                                                       ; +0x63, 0x10041b9c3\ncall    qword ptr [rax+200h]                                           ; +0x66, 0x10041b9c6\nmov     r14, rax                                                       ; +0x6c, 0x10041b9cc\ntest    rax, rax                                                       ; +0x6f, 0x10041b9cf\njz      short loc_10041BA03                                            ; +0x72, 0x10041b9d2\nmov     rdi, r14; lpsrc                                                ; +0x74, 0x10041b9d4\nmov     rsi, r15; lpstype                                              ; +0x77, 0x10041b9d7\nmov     rdx, r12; lpdtype                                              ; +0x7a, 0x10041b9da\nmov     rcx, 0FFFFFFFFFFFFFFFEh; s2d                                   ; +0x7d, 0x10041b9dd\ncall    ___dynamic_cast                                                ; +0x84, 0x10041b9e4\ntest    rax, rax                                                       ; +0x89, 0x10041b9e9\njz      short loc_10041B9C0                                            ; +0x8c, 0x10041b9ec\nmov     rcx, [rax]                                                     ; +0x8e, 0x10041b9ee\nmov     rdi, rax                                                       ; +0x91, 0x10041b9f1\nmov     rsi, r13                                                       ; +0x94, 0x10041b9f4\ncall    qword ptr [rcx+10h]                                            ; +0x97, 0x10041b9f7\ntest    al, al                                                         ; +0x9a, 0x10041b9fa\njnz     short loc_10041B9C0                                            ; +0x9c, 0x10041b9fc\njmp     loc_10041BAD5                                                  ; +0x9e, 0x10041b9fe\nmov     rsi, [rbp-40h]                                                 ; +0xa3, 0x10041ba03\nmov     [rbx+1A0h], rsi                                                ; +0xa7, 0x10041ba07\nlea     r14, [rbp-48h]                                                 ; +0xae, 0x10041ba0e\nmov     rdi, r14                                                       ; +0xb2, 0x10041ba12\ncall    cocos2d__CCTouch__getLocationInView                            ; +0xb5, 0x10041ba15\ncall    cocos2d__CCDirector__sharedDirector                            ; +0xba, 0x10041ba1a\nlea     r15, [rbp-38h]                                                 ; +0xbf, 0x10041ba1f\nmov     rdi, r15                                                       ; +0xc3, 0x10041ba23\nmov     rsi, rax                                                       ; +0xc6, 0x10041ba26\nmov     rdx, r14                                                       ; +0xc9, 0x10041ba29\ncall    cocos2d__CCDirector__convertToGL                               ; +0xcc, 0x10041ba2c\nlea     r12, [rbx+1A8h]                                                ; +0xd1, 0x10041ba31\nmov     rdi, r12                                                       ; +0xd8, 0x10041ba38\nmov     rsi, r15                                                       ; +0xdb, 0x10041ba3b\ncall    sub_100278300                                                  ; +0xde, 0x10041ba3e\nlea     rdi, [rbx+1B0h]                                                ; +0xe3, 0x10041ba43\nmov     rsi, rax                                                       ; +0xea, 0x10041ba4a\ncall    sub_100278300                                                  ; +0xed, 0x10041ba4d\nmov     rdi, r15                                                       ; +0xf2, 0x10041ba52\nmov     rsi, rbx                                                       ; +0xf5, 0x10041ba55\nmov     rdx, r12                                                       ; +0xf8, 0x10041ba58\ncall    cocos2d__CCNode__convertToNodeSpace                            ; +0xfb, 0x10041ba5b\nmov     rdi, r14                                                       ; +0x100, 0x10041ba60\nmov     rsi, r15                                                       ; +0x103, 0x10041ba63\ncall    sub_100278300                                                  ; +0x106, 0x10041ba66\nmov     rdi, r15                                                       ; +0x10b, 0x10041ba6b\ncall    sub_1002787A0                                                  ; +0x10e, 0x10041ba6e\nlea     rsi, qword_100BE38C8                                           ; +0x113, 0x10041ba73\nmov     rdi, r15                                                       ; +0x11a, 0x10041ba7a\ncall    sub_100278300                                                  ; +0x11d, 0x10041ba7d\nmov     rax, [rbx]                                                     ; +0x122, 0x10041ba82\nmov     rdi, rbx                                                       ; +0x125, 0x10041ba85\ncall    qword ptr [rax+148h]                                           ; +0x128, 0x10041ba88\nlea     rdi, [rbp-30h]                                                 ; +0x12e, 0x10041ba8e\nmov     rsi, rax                                                       ; +0x132, 0x10041ba92\ncall    sub_100278660                                                  ; +0x135, 0x10041ba95\nmov     rdi, r15                                                       ; +0x13a, 0x10041ba9a\nmov     rsi, r14                                                       ; +0x13d, 0x10041ba9d\ncall    sub_100278940                                                  ; +0x140, 0x10041baa0\ntest    al, al                                                         ; +0x145, 0x10041baa5\njz      short loc_10041BAD5                                            ; +0x147, 0x10041baa7\nmov     rdi, [rbx+1E8h]                                                ; +0x149, 0x10041baa9\ncall    cocos2d__CCNode__stopAllActions                                ; +0x150, 0x10041bab0\nlea     rdi, [rbx+1B8h]                                                ; +0x155, 0x10041bab5\nxor     esi, esi                                                       ; +0x15c, 0x10041babc\ncall    cocos2d__CCTime__gettimeofdayCocos2d                           ; +0x15e, 0x10041babe\nmov     byte ptr [rbx+1C8h], 1                                         ; +0x163, 0x10041bac3\nmovzx   eax, byte ptr [rbx+1F5h]                                       ; +0x16a, 0x10041baca\nxor     al, 1                                                          ; +0x171, 0x10041bad1\njmp     short loc_10041BAD7                                            ; +0x173, 0x10041bad3\nxor     eax, eax                                                       ; +0x175, 0x10041bad5\nadd     rsp, 28h                                                       ; +0x177, 0x10041bad7\npop     rbx                                                            ; +0x17b, 0x10041badb\npop     r12                                                            ; +0x17c, 0x10041badc\npop     r13                                                            ; +0x17e, 0x10041bade\npop     r14                                                            ; +0x180, 0x10041bae0\npop     r15                                                            ; +0x182, 0x10041bae2\npop     rbp                                                            ; +0x184, 0x10041bae4\nretn                                                                   ; +0x185, 0x10041bae5", "xrefs": ["sub_10041BAF0 @ 0x10041bafc", "TableView::ccTouchBegan @ 0x1006ff465", "<???> @ 0x100b3fc78"], "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"}