{"type": "func", "start": 6442825904, "end": 6442826033, "name": "cocos2d::CCMenu::registerWithTouchDispatcher", "pseudocode": "// \n// cocos2d::CCMenu::registerWithTouchDispatcher from 0x18005b8b0 to 0x18005b931 (129 bytes)\n// \n// 3 xrefs:\n// > <???> @ 0x1800fd4a8\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801bce14\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:21:49 +0000\n// \n\nvoid __fastcall cocos2d::CCMenu::registerWithTouchDispatcher(cocos2d::CCMenu *this)\n{\n  struct cocos2d::CCDirector *v2; // r14\n  __int64 (__fastcall *v3)(struct cocos2d::CCDirector *); // rdi\n  int v4; // esi\n  struct cocos2d::CCTouchDelegate *v5; // rbx\n  cocos2d::CCTouchDispatcher *v6; // rax\n\n  v2 = cocos2d::CCDirector::sharedDirector();\n  v3 = *(__int64 (__fastcall **)(struct cocos2d::CCDirector *))(*(_QWORD *)v2 + 144LL);\n  v4 = (*(__int64 (__fastcall **)(cocos2d::CCMenu *))(*(_QWORD *)this + 952LL))(this);\n  v5 = (cocos2d::CCMenu *)((char *)this + 320);\n  if ( !this )\n    v5 = nullptr;\n  v6 = (cocos2d::CCTouchDispatcher *)v3(v2);\n  cocos2d::CCTouchDispatcher::addTargetedDelegate(v6, v5, v4, 1);\n}", "assembly": "; \n; cocos2d::CCMenu::registerWithTouchDispatcher from 0x18005b8b0 to 0x18005b931 (129 bytes)\n; \n; 3 xrefs:\n; > <???> @ 0x1800fd4a8\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801bce14\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:21:49 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x18005b8b0\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x18005b8b5\nmov     [rsp+arg_10], rdi                                              ; +0xa, 0x18005b8ba\nmov     [rsp+arg_18], r14                                              ; +0xf, 0x18005b8bf\npush    r15                                                            ; +0x14, 0x18005b8c4\nsub     rsp, 20h                                                       ; +0x16, 0x18005b8c6\nmov     r15, rcx                                                       ; +0x1a, 0x18005b8ca\ncall    ?sharedDirector@CCDirector@cocos2d@@SAPEAV12@XZ; cocos2d::CCDirector::sharedDirector(void) ; +0x1d, 0x18005b8cd\nmov     rdx, [r15]                                                     ; +0x22, 0x18005b8d2\nmov     rcx, r15                                                       ; +0x25, 0x18005b8d5\nmov     r14, rax                                                       ; +0x28, 0x18005b8d8\nmov     r8, [rdx+3B8h]                                                 ; +0x2b, 0x18005b8db\nmov     rdx, [rax]                                                     ; +0x32, 0x18005b8e2\nmov     rdi, [rdx+90h]                                                 ; +0x35, 0x18005b8e5\ncall    r8                                                             ; +0x3c, 0x18005b8ec\nmov     esi, eax                                                       ; +0x3f, 0x18005b8ef\nlea     rbx, [r15+140h]                                                ; +0x41, 0x18005b8f1\nxor     eax, eax                                                       ; +0x48, 0x18005b8f8\nmov     rcx, r14                                                       ; +0x4a, 0x18005b8fa\ntest    r15, r15                                                       ; +0x4d, 0x18005b8fd\ncmovz   rbx, rax                                                       ; +0x50, 0x18005b900\ncall    rdi                                                            ; +0x54, 0x18005b904\nmov     rcx, rax; this                                                 ; +0x56, 0x18005b906\nmov     r9b, 1; bool                                                   ; +0x59, 0x18005b909\nmov     r8d, esi; int                                                  ; +0x5c, 0x18005b90c\nmov     rdx, rbx; struct cocos2d::CCTouchDelegate *                    ; +0x5f, 0x18005b90f\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x62, 0x18005b912\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x67, 0x18005b917\nmov     rdi, [rsp+28h+arg_10]                                          ; +0x6c, 0x18005b91c\nmov     r14, [rsp+28h+arg_18]                                          ; +0x71, 0x18005b921\nadd     rsp, 20h                                                       ; +0x76, 0x18005b926\npop     r15                                                            ; +0x7a, 0x18005b92a\njmp     ?addTargetedDelegate@CCTouchDispatcher@cocos2d@@QEAAXPEAVCCTouchDelegate@2@H_N@Z; cocos2d::CCTouchDispatcher::addTargetedDelegate(cocos2d::CCTouchDelegate *,int,bool) ; +0x7c, 0x18005b92c", "xrefs": ["<???> @ 0x1800fd4a8", "<???> @ 0x18014cf68", "<???> @ 0x1801bce14"], "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"}