{"type": "func", "start": 6443113984, "end": 6443114044, "name": "sub_1800A1E00", "pseudocode": "// \n// sub_1800A1E00 from 0x1800a1e00 to 0x1800a1e3c (60 bytes)\n// \n// 6 xrefs:\n// > cocos2d::CCKeyboardDispatcher::addDelegate @ 0x180045ad5\n// > cocos2d::CCMouseDispatcher::removeDelegate @ 0x180047171\n// > cocos2d::CCMouseDispatcher::addDelegate @ 0x180062ee5\n// > cocos2d::CCTouchDispatcher::removeDelegate @ 0x1800b6de6\n// > cocos2d::CCKeypadDispatcher::addDelegate @ 0x1800b8145\n// > <???> @ 0x1801c1800\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:13 +0000\n// \n\nvoid *__fastcall sub_1800A1E00(__int64 a1, __int64 a2)\n{\n  void *result; // rax\n  unsigned int v4; // eax\n\n  *(_QWORD *)(*(_QWORD *)(a1 + 16) + 8LL * (unsigned int)(*(_DWORD *)a1)++) = a2;\n  result = (void *)*(unsigned int *)(a1 + 4);\n  if ( *(_DWORD *)a1 >= (unsigned int)result )\n  {\n    v4 = 2 * (_DWORD)result;\n    *(_DWORD *)(a1 + 4) = v4;\n    result = realloc(*(void **)(a1 + 16), 8LL * v4);\n    *(_QWORD *)(a1 + 16) = result;\n  }\n  return result;\n}", "assembly": "; \n; sub_1800A1E00 from 0x1800a1e00 to 0x1800a1e3c (60 bytes)\n; \n; 6 xrefs:\n; > cocos2d::CCKeyboardDispatcher::addDelegate @ 0x180045ad5\n; > cocos2d::CCMouseDispatcher::removeDelegate @ 0x180047171\n; > cocos2d::CCMouseDispatcher::addDelegate @ 0x180062ee5\n; > cocos2d::CCTouchDispatcher::removeDelegate @ 0x1800b6de6\n; > cocos2d::CCKeypadDispatcher::addDelegate @ 0x1800b8145\n; > <???> @ 0x1801c1800\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:13 +0000\n; \npush    rbx                                                            ; +0x0, 0x1800a1e00\nsub     rsp, 20h                                                       ; +0x2, 0x1800a1e02\nmov     r8d, [rcx]                                                     ; +0x6, 0x1800a1e06\nmov     rbx, rcx                                                       ; +0x9, 0x1800a1e09\nmov     rax, [rcx+10h]                                                 ; +0xc, 0x1800a1e0c\nmov     [rax+r8*8], rdx                                                ; +0x10, 0x1800a1e10\ninc     dword ptr [rcx]                                                ; +0x14, 0x1800a1e14\nmov     eax, [rcx+4]                                                   ; +0x16, 0x1800a1e16\ncmp     [rcx], eax                                                     ; +0x19, 0x1800a1e19\njb      short loc_1800A1E36                                            ; +0x1b, 0x1800a1e1b\nadd     eax, eax                                                       ; +0x1d, 0x1800a1e1d\nmov     edx, eax                                                       ; +0x1f, 0x1800a1e1f\nmov     [rcx+4], eax                                                   ; +0x21, 0x1800a1e21\nmov     rcx, [rcx+10h]; Block                                          ; +0x24, 0x1800a1e24\nshl     rdx, 3; Size                                                   ; +0x28, 0x1800a1e28\ncall    cs:realloc                                                     ; +0x2c, 0x1800a1e2c\nmov     [rbx+10h], rax                                                 ; +0x32, 0x1800a1e32\nadd     rsp, 20h                                                       ; +0x36, 0x1800a1e36\npop     rbx                                                            ; +0x3a, 0x1800a1e3a\nretn                                                                   ; +0x3b, 0x1800a1e3b", "xrefs": ["cocos2d::CCKeyboardDispatcher::addDelegate @ 0x180045ad5", "cocos2d::CCMouseDispatcher::removeDelegate @ 0x180047171", "cocos2d::CCMouseDispatcher::addDelegate @ 0x180062ee5", "cocos2d::CCTouchDispatcher::removeDelegate @ 0x1800b6de6", "cocos2d::CCKeypadDispatcher::addDelegate @ 0x1800b8145", "<???> @ 0x1801c1800"], "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"}