{"type": "func", "start": 6443191552, "end": 6443191666, "name": "cocos2d::CCIMEDispatcher::removeDelegate", "pseudocode": "// \n// cocos2d::CCIMEDispatcher::removeDelegate from 0x1800b4d00 to 0x1800b4d72 (114 bytes)\n// \n// 1 xrefs:\n// > <???> @ 0x1801438a8\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\nvoid __fastcall cocos2d::CCIMEDispatcher::removeDelegate(\n        cocos2d::CCIMEDispatcher *this,\n        struct cocos2d::CCIMEDelegate *a2)\n{\n  cocos2d::CCIMEDispatcher::Impl *m_pImpl; // r8\n  void **v4; // rax\n  struct cocos2d::CCIMEDelegate *v5; // rcx\n  cocos2d::CCIMEDelegate_vtbl *v6; // rax\n  cocos2d::CCIMEDispatcher::Impl *v7; // r8\n\n  if ( a2 )\n  {\n    m_pImpl = this->m_pImpl;\n    if ( this->m_pImpl )\n    {\n      v4 = *(void ***)m_pImpl;\n      v5 = **(struct cocos2d::CCIMEDelegate ***)m_pImpl;\n      if ( v5 != *(struct cocos2d::CCIMEDelegate **)m_pImpl )\n      {\n        while ( a2 != (struct cocos2d::CCIMEDelegate *)v5[2].__vftable )\n        {\n          v5 = (struct cocos2d::CCIMEDelegate *)v5->__vftable;\n          if ( v5 == (struct cocos2d::CCIMEDelegate *)v4 )\n            return;\n        }\n        if ( v4 != (void **)v5 )\n        {\n          v6 = *((cocos2d::CCIMEDelegate_vtbl **)m_pImpl + 2);\n          if ( v6 )\n          {\n            if ( v5[2].__vftable == v6 )\n              *((_QWORD *)m_pImpl + 2) = 0;\n          }\n          v7 = this->m_pImpl;\n          v5[1].~CCIMEDelegate = (void (__stdcall *)(cocos2d::CCIMEDelegate *__hidden))v5->__vftable;\n          v5->attachWithIME = (bool (__stdcall *)(cocos2d::CCIMEDelegate *__hidden))v5[1].__vftable;\n          --*((_QWORD *)v7 + 1);\n          j_j_free_0(v5);\n        }\n      }\n    }\n  }\n}", "assembly": "; \n; cocos2d::CCIMEDispatcher::removeDelegate from 0x1800b4d00 to 0x1800b4d72 (114 bytes)\n; \n; 1 xrefs:\n; > <???> @ 0x1801438a8\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     r9, rcx                                                        ; +0x0, 0x1800b4d00\ntest    rdx, rdx                                                       ; +0x3, 0x1800b4d03\njz      short locret_1800B4D71                                         ; +0x6, 0x1800b4d06\nmov     r8, [rcx]                                                      ; +0x8, 0x1800b4d08\ntest    r8, r8                                                         ; +0xb, 0x1800b4d0b\njz      short locret_1800B4D71                                         ; +0xe, 0x1800b4d0e\nmov     rax, [r8]                                                      ; +0x10, 0x1800b4d10\nmov     rcx, [rax]; Block                                              ; +0x13, 0x1800b4d13\ncmp     rcx, rax                                                       ; +0x16, 0x1800b4d16\njz      short locret_1800B4D71                                         ; +0x19, 0x1800b4d19\nnop     dword ptr [rax+rax+00h]                                        ; +0x1b, 0x1800b4d1b\ncmp     rdx, [rcx+10h]                                                 ; +0x20, 0x1800b4d20\njz      short loc_1800B4D2F                                            ; +0x24, 0x1800b4d24\nmov     rcx, [rcx]                                                     ; +0x26, 0x1800b4d26\ncmp     rcx, rax                                                       ; +0x29, 0x1800b4d29\njnz     short loc_1800B4D20                                            ; +0x2c, 0x1800b4d2c\nretn                                                                   ; +0x2e, 0x1800b4d2e\ncmp     rax, rcx                                                       ; +0x2f, 0x1800b4d2f\njz      short locret_1800B4D71                                         ; +0x32, 0x1800b4d32\nmov     rax, [r8+10h]                                                  ; +0x34, 0x1800b4d34\ntest    rax, rax                                                       ; +0x38, 0x1800b4d38\njz      short loc_1800B4D4B                                            ; +0x3b, 0x1800b4d3b\ncmp     [rcx+10h], rax                                                 ; +0x3d, 0x1800b4d3d\njnz     short loc_1800B4D4B                                            ; +0x41, 0x1800b4d41\nmov     qword ptr [r8+10h], 0                                          ; +0x43, 0x1800b4d43\nmov     rdx, [rcx+8]                                                   ; +0x4b, 0x1800b4d4b\nmov     rax, [rcx]                                                     ; +0x4f, 0x1800b4d4f\nmov     r8, [r9]                                                       ; +0x52, 0x1800b4d52\nmov     [rdx], rax                                                     ; +0x55, 0x1800b4d55\nmov     rdx, [rcx]                                                     ; +0x58, 0x1800b4d58\nmov     rax, [rcx+8]                                                   ; +0x5b, 0x1800b4d5b\nmov     [rdx+8], rax                                                   ; +0x5f, 0x1800b4d5f\nmov     edx, 18h                                                       ; +0x63, 0x1800b4d63\ndec     qword ptr [r8+8]                                               ; +0x68, 0x1800b4d68\njmp     j_j_free_0                                                     ; +0x6c, 0x1800b4d6c\nretn                                                                   ; +0x71, 0x1800b4d71", "xrefs": ["<???> @ 0x1801438a8"], "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"}