{"type": "func", "start": 6443202800, "end": 6443202986, "name": "cocos2d::CCStandardTouchHandler::handlerWithDelegate", "pseudocode": "// \n// cocos2d::CCStandardTouchHandler::handlerWithDelegate from 0x1800b78f0 to 0x1800b79aa (186 bytes)\n// \n// 3 xrefs:\n// > cocos2d::CCTouchDispatcher::addStandardDelegate @ 0x1800b64ab\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801c2a9c\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 11:22:22 +0000\n// \n\n// Hidden C++ exception states: #wind=1\nstruct cocos2d::CCStandardTouchHandler *__fastcall cocos2d::CCStandardTouchHandler::handlerWithDelegate(\n        struct cocos2d::CCTouchDelegate *a1,\n        unsigned int a2)\n{\n  __int64 v4; // rbx\n  bool (__fastcall *v5)(cocos2d::CCTouchHandler *__hidden, struct cocos2d::CCTouchDelegate *, int); // r9\n  bool v6; // al\n\n  v4 = sub_1800E4AC0(0x48u);\n  if ( v4 )\n  {\n    *(_OWORD *)v4 = 0;\n    *(_OWORD *)(v4 + 16) = 0;\n    *(_OWORD *)(v4 + 32) = 0;\n    *(_OWORD *)(v4 + 48) = 0;\n    *(_QWORD *)(v4 + 64) = 0;\n    cocos2d::CCObject::CCObject((cocos2d::CCObject *)v4);\n    *(_QWORD *)v4 = &cocos2d::CCStandardTouchHandler::`vftable';\n  }\n  else\n  {\n    v4 = 0;\n  }\n  if ( !v4 )\n    return (struct cocos2d::CCStandardTouchHandler *)v4;\n  v5 = *(bool (__fastcall **)(cocos2d::CCTouchHandler *__hidden, struct cocos2d::CCTouchDelegate *, int))(*(_QWORD *)v4 + 72LL);\n  if ( v5 == cocos2d::CCTouchHandler::initWithDelegate )\n    v6 = cocos2d::CCTouchHandler::initWithDelegate((cocos2d::CCTouchHandler *)v4, a1, a2);\n  else\n    v6 = v5((cocos2d::CCTouchHandler *)v4, a1, a2);\n  if ( v6 )\n  {\n    cocos2d::CCObject::autorelease((cocos2d::CCObject *)v4);\n    return (struct cocos2d::CCStandardTouchHandler *)v4;\n  }\n  cocos2d::CCObject::release((cocos2d::CCObject *)v4);\n  return nullptr;\n}", "assembly": "; \n; cocos2d::CCStandardTouchHandler::handlerWithDelegate from 0x1800b78f0 to 0x1800b79aa (186 bytes)\n; \n; 3 xrefs:\n; > cocos2d::CCTouchDispatcher::addStandardDelegate @ 0x1800b64ab\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801c2a9c\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 11:22:22 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800b78f0\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x1800b78f5\npush    rdi                                                            ; +0xa, 0x1800b78fa\nsub     rsp, 20h                                                       ; +0xb, 0x1800b78fb\nmov     edi, edx                                                       ; +0xf, 0x1800b78ff\nmov     rsi, rcx                                                       ; +0x11, 0x1800b7901\nmov     ecx, 48h ; 'H'; Size                                           ; +0x14, 0x1800b7904\ncall    sub_1800E4AC0                                                  ; +0x19, 0x1800b7909\nmov     rbx, rax                                                       ; +0x1e, 0x1800b790e\nmov     [rsp+28h+arg_10], rax                                          ; +0x21, 0x1800b7911\ntest    rax, rax                                                       ; +0x26, 0x1800b7916\njz      short loc_1800B7947                                            ; +0x29, 0x1800b7919\nxorps   xmm0, xmm0                                                     ; +0x2b, 0x1800b791b\nxor     eax, eax                                                       ; +0x2e, 0x1800b791e\nmovups  xmmword ptr [rbx], xmm0                                        ; +0x30, 0x1800b7920\nmovups  xmmword ptr [rbx+10h], xmm0                                    ; +0x33, 0x1800b7923\nmovups  xmmword ptr [rbx+20h], xmm0                                    ; +0x37, 0x1800b7927\nmovups  xmmword ptr [rbx+30h], xmm0                                    ; +0x3b, 0x1800b792b\nmov     [rbx+40h], rax                                                 ; +0x3f, 0x1800b792f\nmov     rcx, rbx; this                                                 ; +0x43, 0x1800b7933\ncall    ??0CCObject@cocos2d@@QEAA@XZ; cocos2d::CCObject::CCObject(void) ; +0x46, 0x1800b7936\nlea     rax, ??_7CCStandardTouchHandler@cocos2d@@6B@; const cocos2d::CCStandardTouchHandler::`vftable' ; +0x4b, 0x1800b793b\nmov     [rbx], rax                                                     ; +0x52, 0x1800b7942\njmp     short loc_1800B7949                                            ; +0x55, 0x1800b7945\nxor     ebx, ebx                                                       ; +0x57, 0x1800b7947\ntest    rbx, rbx                                                       ; +0x59, 0x1800b7949\njz      short loc_1800B7980                                            ; +0x5c, 0x1800b794c\nmov     rax, [rbx]                                                     ; +0x5e, 0x1800b794e\nmov     r9, [rax+48h]                                                  ; +0x61, 0x1800b7951\nlea     rax, ?initWithDelegate@CCTouchHandler@cocos2d@@UEAA_NPEAVCCTouchDelegate@2@H@Z; cocos2d::CCTouchHandler::initWithDelegate(cocos2d::CCTouchDelegate *,int) ; +0x65, 0x1800b7955\nmov     r8d, edi; int                                                  ; +0x6c, 0x1800b795c\nmov     rdx, rsi; struct cocos2d::CCTouchDelegate *                    ; +0x6f, 0x1800b795f\nmov     rcx, rbx; this                                                 ; +0x72, 0x1800b7962\ncmp     r9, rax                                                        ; +0x75, 0x1800b7965\njnz     short loc_1800B7971                                            ; +0x78, 0x1800b7968\ncall    ?initWithDelegate@CCTouchHandler@cocos2d@@UEAA_NPEAVCCTouchDelegate@2@H@Z; cocos2d::CCTouchHandler::initWithDelegate(cocos2d::CCTouchDelegate *,int) ; +0x7a, 0x1800b796a\njmp     short loc_1800B7974                                            ; +0x7f, 0x1800b796f\ncall    r9                                                             ; +0x81, 0x1800b7971\nmov     rcx, rbx; this                                                 ; +0x84, 0x1800b7974\ntest    al, al                                                         ; +0x87, 0x1800b7977\njz      short loc_1800B7993                                            ; +0x89, 0x1800b7979\ncall    ?autorelease@CCObject@cocos2d@@QEAAPEAV12@XZ; cocos2d::CCObject::autorelease(void) ; +0x8b, 0x1800b797b\nmov     rax, rbx                                                       ; +0x90, 0x1800b7980\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x93, 0x1800b7983\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x98, 0x1800b7988\nadd     rsp, 20h                                                       ; +0x9d, 0x1800b798d\npop     rdi                                                            ; +0xa1, 0x1800b7991\nretn                                                                   ; +0xa2, 0x1800b7992\ncall    ?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0xa3, 0x1800b7993\nxor     eax, eax                                                       ; +0xa8, 0x1800b7998\nmov     rbx, [rsp+28h+arg_0]                                           ; +0xaa, 0x1800b799a\nmov     rsi, [rsp+28h+arg_8]                                           ; +0xaf, 0x1800b799f\nadd     rsp, 20h                                                       ; +0xb4, 0x1800b79a4\npop     rdi                                                            ; +0xb8, 0x1800b79a8\nretn                                                                   ; +0xb9, 0x1800b79a9", "xrefs": ["cocos2d::CCTouchDispatcher::addStandardDelegate @ 0x1800b64ab", "<???> @ 0x18014cf68", "<???> @ 0x1801c2a9c"], "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"}