{"type": "func", "start": 6442591360, "end": 6442591535, "name": "sub_180022480", "pseudocode": "// \n// sub_180022480 from 0x180022480 to 0x18002252f (175 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x1800e71d0\n// > <???> @ 0x1801aef44\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\n// Hidden C++ exception states: #wind=1\ncocos2d::CCObject *__fastcall sub_180022480(cocos2d::CCObject *this, char a2)\n{\n  cocos2d::CCObject *v5; // rcx\n  cocos2d::CCObject *v6; // rcx\n\n  if ( (a2 & 2) != 0 )\n  {\n    `eh vector destructor iterator'(\n      this,\n      0x78u,\n      *((_QWORD *)this - 1),\n      (void (*)(void *))cocos2d::CCGridBase::~CCGridBase);\n    if ( (a2 & 1) != 0 )\n      j_j_j_free_0((char *)this - 8);\n    return (cocos2d::CCObject *)((char *)this - 8);\n  }\n  else\n  {\n    this->__vftable = (cocos2d::CCObject_vtbl *)&cocos2d::CCGridBase::`vftable';\n    v5 = *((cocos2d::CCObject **)this + 9);\n    if ( v5 )\n      cocos2d::CCObject::release(v5);\n    v6 = *((cocos2d::CCObject **)this + 11);\n    if ( v6 )\n      cocos2d::CCObject::release(v6);\n    cocos2d::CCObject::~CCObject(this);\n    if ( (a2 & 1) != 0 )\n      j_j_free_0(this);\n    return this;\n  }\n}", "assembly": "; \n; sub_180022480 from 0x180022480 to 0x18002252f (175 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x1800e71d0\n; > <???> @ 0x1801aef44\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     [rsp+arg_0], rbx                                               ; +0x0, 0x180022480\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x180022485\npush    rdi                                                            ; +0xa, 0x18002248a\nsub     rsp, 20h                                                       ; +0xb, 0x18002248b\nmov     esi, edx                                                       ; +0xf, 0x18002248f\nmov     rbx, rcx                                                       ; +0x11, 0x180022491\ntest    dl, 2                                                          ; +0x14, 0x180022494\njz      short loc_1800224DA                                            ; +0x17, 0x180022497\nlea     r9, ??1CCGridBase@cocos2d@@UEAA@XZ; void (*)(void *)           ; +0x19, 0x180022499\nmov     r8, [rcx-8]; unsigned __int64                                  ; +0x20, 0x1800224a0\nmov     edx, 78h ; 'x'; unsigned __int64                               ; +0x24, 0x1800224a4\ncall    ??_M@YAXPEAX_K1P6AX0@Z@Z; `eh vector destructor iterator'(void *,unsigned __int64,unsigned __int64,void (*)(void *)) ; +0x29, 0x1800224a9\ntest    sil, 1                                                         ; +0x2e, 0x1800224ae\njz      short loc_1800224C6                                            ; +0x32, 0x1800224b2\nimul    rdx, [rbx-8], 78h ; 'x'                                        ; +0x34, 0x1800224b4\nadd     rdx, 8                                                         ; +0x39, 0x1800224b9\nlea     rcx, [rbx-8]; Block                                            ; +0x3d, 0x1800224bd\ncall    j_j_j_free_0                                                   ; +0x41, 0x1800224c1\nlea     rax, [rbx-8]                                                   ; +0x46, 0x1800224c6\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x4a, 0x1800224ca\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x4f, 0x1800224cf\nadd     rsp, 20h                                                       ; +0x54, 0x1800224d4\npop     rdi                                                            ; +0x58, 0x1800224d8\nretn                                                                   ; +0x59, 0x1800224d9\nlea     rax, ??_7CCGridBase@cocos2d@@6B@; const cocos2d::CCGridBase::`vftable' ; +0x5a, 0x1800224da\nmov     [rcx], rax                                                     ; +0x61, 0x1800224e1\nmov     rcx, [rcx+48h]; this                                           ; +0x64, 0x1800224e4\ntest    rcx, rcx                                                       ; +0x68, 0x1800224e8\njz      short loc_1800224F2                                            ; +0x6b, 0x1800224eb\ncall    ?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x6d, 0x1800224ed\nmov     rcx, [rbx+58h]; this                                           ; +0x72, 0x1800224f2\ntest    rcx, rcx                                                       ; +0x76, 0x1800224f6\njz      short loc_180022500                                            ; +0x79, 0x1800224f9\ncall    ?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x7b, 0x1800224fb\nmov     rcx, rbx; this                                                 ; +0x80, 0x180022500\ncall    ??1CCObject@cocos2d@@UEAA@XZ; cocos2d::CCObject::~CCObject(void) ; +0x83, 0x180022503\nnop                                                                    ; +0x88, 0x180022508\ntest    sil, 1                                                         ; +0x89, 0x180022509\njz      short loc_18002251C                                            ; +0x8d, 0x18002250d\nmov     edx, 78h ; 'x'                                                 ; +0x8f, 0x18002250f\nmov     rcx, rbx; Block                                                ; +0x94, 0x180022514\ncall    j_j_free_0                                                     ; +0x97, 0x180022517\nmov     rax, rbx                                                       ; +0x9c, 0x18002251c\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x9f, 0x18002251f\nmov     rsi, [rsp+28h+arg_8]                                           ; +0xa4, 0x180022524\nadd     rsp, 20h                                                       ; +0xa9, 0x180022529\npop     rdi                                                            ; +0xad, 0x18002252d\nretn                                                                   ; +0xae, 0x18002252e", "xrefs": ["<???> @ 0x1800e71d0", "<???> @ 0x1801aef44"], "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"}