{"type": "func", "start": 6442536720, "end": 6442537174, "name": "cocos2d::extension::CCTableView::insertCellAtIndex", "pseudocode": "// \n// cocos2d::extension::CCTableView::insertCellAtIndex from 0x180014f10 to 0x1800150d6 (454 bytes)\n// \n// 4 xrefs:\n// > <???> @ 0x180031344\n// > <???> @ 0x180031384\n// > <???> @ 0x180032408\n// > <???> @ 0x18004c6a4\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 12:15:41 +0000\n// \n\nvoid __fastcall cocos2d::extension::CCTableView::insertCellAtIndex(\n        cocos2d::extension::CCTableView *this,\n        unsigned int a2)\n{\n  int v4; // eax\n  struct cocos2d::extension::CCSortableObject *v5; // rax\n  char *v6; // rcx\n  unsigned int v7; // ebx\n  __int64 v8; // rsi\n  char *v9; // rcx\n  unsigned int v10; // r14d\n  unsigned int v11; // ebp\n  unsigned int *v12; // rsi\n  __int64 v13; // rax\n  _QWORD *v14; // rsi\n  _QWORD *i; // r15\n  __int64 v16; // rax\n  unsigned int v17; // eax\n  struct cocos2d::CCObject *v18; // rax\n  struct cocos2d::extension::CCTableViewCell *v19; // rbx\n\n  if ( a2 != -1 )\n  {\n    v4 = (*(__int64 (__fastcall **)(_QWORD, cocos2d::extension::CCTableView *))(**((_QWORD **)this + 80) + 32LL))(\n           *((_QWORD *)this + 80),\n           this);\n    if ( v4 )\n    {\n      if ( a2 <= v4 - 1 )\n      {\n        v5 = cocos2d::extension::CCArrayForObjectSorting::objectWithObjectID(\n               *((cocos2d::extension::CCArrayForObjectSorting **)this + 78),\n               a2);\n        v6 = (char *)v5 - 320;\n        if ( !v5 )\n          v6 = nullptr;\n        if ( v6 )\n        {\n          v7 = 0;\n          v8 = *((_QWORD *)this + 78);\n          v9 = v6 + 320;\n          if ( v9 )\n          {\n            v10 = 0;\n            v11 = (*(__int64 (__fastcall **)(char *))(*(_QWORD *)v9 + 16LL))(v9);\n            if ( v8 )\n            {\n              v12 = *(unsigned int **)(v8 + 56);\n              v13 = *v12;\n              if ( (_DWORD)v13 )\n              {\n                v14 = *((_QWORD **)v12 + 2);\n                for ( i = &v14[v13 - 1]; v14 <= i; v10 = v17 )\n                {\n                  if ( !*v14 )\n                    break;\n                  v16 = _RTDynamicCast(\n                          *v14,\n                          0,\n                          &cocos2d::CCObject `RTTI Type Descriptor',\n                          &cocos2d::extension::CCSortableObject `RTTI Type Descriptor',\n                          0);\n                  v17 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v16 + 16LL))(v16);\n                  if ( v11 == v17 || v11 >= v10 && v11 < v17 )\n                    break;\n                  ++v7;\n                  ++v14;\n                }\n              }\n            }\n          }\n          else\n          {\n            v7 = -1;\n          }\n          for ( ; v7 < cocos2d::CCArray::count(*((cocos2d::CCArray **)this + 78)); ++v7 )\n          {\n            v18 = cocos2d::CCArray::objectAtIndex(*((cocos2d::CCArray **)this + 78), v7);\n            cocos2d::extension::CCTableView::_setIndexForCell(this, *((_DWORD *)v18 + 82) + 1, v18);\n          }\n        }\n        v19 = (struct cocos2d::extension::CCTableViewCell *)(*(__int64 (__fastcall **)(_QWORD, cocos2d::extension::CCTableView *, _QWORD))(**((_QWORD **)this + 80) + 24LL))(\n                                                              *((_QWORD *)this + 80),\n                                                              this,\n                                                              a2);\n        cocos2d::extension::CCTableView::_setIndexForCell(this, a2, v19);\n        cocos2d::extension::CCTableView::_addCellIfNecessary(this, v19);\n        cocos2d::extension::CCTableView::_updateCellPositions(this);\n        cocos2d::extension::CCTableView::_updateContentSize(this);\n      }\n    }\n  }\n}", "assembly": "; \n; cocos2d::extension::CCTableView::insertCellAtIndex from 0x180014f10 to 0x1800150d6 (454 bytes)\n; \n; 4 xrefs:\n; > <???> @ 0x180031344\n; > <???> @ 0x180031384\n; > <???> @ 0x180032408\n; > <???> @ 0x18004c6a4\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 12:15:41 +0000\n; \ncmp     edx, 0FFFFFFFFh                                                ; +0x0, 0x180014f10\njz      locret_1800150D5                                               ; +0x3, 0x180014f13\npush    rdi                                                            ; +0x9, 0x180014f19\npush    r12                                                            ; +0xa, 0x180014f1a\nsub     rsp, 48h                                                       ; +0xc, 0x180014f1c\nmov     rdi, rcx                                                       ; +0x10, 0x180014f20\nmov     r12d, edx                                                      ; +0x13, 0x180014f23\nmov     rcx, [rcx+280h]                                                ; +0x16, 0x180014f26\nmov     rdx, rdi                                                       ; +0x1d, 0x180014f2d\nmov     rax, [rcx]                                                     ; +0x20, 0x180014f30\ncall    qword ptr [rax+20h]                                            ; +0x23, 0x180014f33\ntest    eax, eax                                                       ; +0x26, 0x180014f36\njz      loc_1800150CE                                                  ; +0x28, 0x180014f38\ndec     eax                                                            ; +0x2e, 0x180014f3e\ncmp     r12d, eax                                                      ; +0x30, 0x180014f40\nja      loc_1800150CE                                                  ; +0x33, 0x180014f43\nmov     rcx, [rdi+270h]; this                                          ; +0x39, 0x180014f49\nmov     edx, r12d; unsigned int                                        ; +0x40, 0x180014f50\nmov     [rsp+58h+arg_0], rbx                                           ; +0x43, 0x180014f53\nmov     [rsp+58h+var_18], r13                                          ; +0x48, 0x180014f58\ncall    ?objectWithObjectID@CCArrayForObjectSorting@extension@cocos2d@@QEAAPEAVCCSortableObject@23@I@Z; cocos2d::extension::CCArrayForObjectSorting::objectWithObjectID(uint) ; +0x4d, 0x180014f5d\nxor     r13d, r13d                                                     ; +0x52, 0x180014f62\ntest    rax, rax                                                       ; +0x55, 0x180014f65\nlea     rcx, [rax-140h]                                                ; +0x58, 0x180014f68\ncmovz   rcx, r13                                                       ; +0x5f, 0x180014f6f\ntest    rcx, rcx                                                       ; +0x63, 0x180014f73\njz      loc_180015085                                                  ; +0x66, 0x180014f76\nmov     [rsp+58h+arg_10], rsi                                          ; +0x6c, 0x180014f7c\nmov     ebx, r13d                                                      ; +0x71, 0x180014f81\nmov     rsi, [rdi+270h]                                                ; +0x74, 0x180014f84\nmov     [rsp+58h+arg_8], rbp                                           ; +0x7b, 0x180014f8b\nmov     [rsp+58h+var_20], r14                                          ; +0x80, 0x180014f90\nmov     [rsp+58h+var_28], r15                                          ; +0x85, 0x180014f95\nadd     rcx, 140h                                                      ; +0x8a, 0x180014f9a\njz      short loc_18001501B                                            ; +0x91, 0x180014fa1\nmov     rax, [rcx]                                                     ; +0x93, 0x180014fa3\nmov     r14d, r13d                                                     ; +0x96, 0x180014fa6\ncall    qword ptr [rax+10h]                                            ; +0x99, 0x180014fa9\nmov     ebp, eax                                                       ; +0x9c, 0x180014fac\ntest    rsi, rsi                                                       ; +0x9e, 0x180014fae\njz      short loc_180015020                                            ; +0xa1, 0x180014fb1\nmov     rsi, [rsi+38h]                                                 ; +0xa3, 0x180014fb3\nmov     eax, [rsi]                                                     ; +0xa7, 0x180014fb7\ntest    eax, eax                                                       ; +0xa9, 0x180014fb9\njz      short loc_180015020                                            ; +0xab, 0x180014fbb\nmov     rsi, [rsi+10h]                                                 ; +0xad, 0x180014fbd\nlea     r15, [rax-1]                                                   ; +0xb1, 0x180014fc1\nlea     r15, [rsi+r15*8]                                               ; +0xb5, 0x180014fc5\ncmp     rsi, r15                                                       ; +0xb9, 0x180014fc9\nja      short loc_180015020                                            ; +0xbc, 0x180014fcc\nxchg    ax, ax                                                         ; +0xbe, 0x180014fce\nmov     rcx, [rsi]                                                     ; +0xc0, 0x180014fd0\ntest    rcx, rcx                                                       ; +0xc3, 0x180014fd3\njz      short loc_180015020                                            ; +0xc6, 0x180014fd6\nlea     r9, ??_R0?AVCCSortableObject@extension@cocos2d@@@8; cocos2d::extension::CCSortableObject `RTTI Type Descriptor' ; +0xc8, 0x180014fd8\nmov     [rsp+58h+var_38], r13d                                         ; +0xcf, 0x180014fdf\nlea     r8, ??_R0?AVCCObject@cocos2d@@@8; cocos2d::CCObject `RTTI Type Descriptor' ; +0xd4, 0x180014fe4\nxor     edx, edx                                                       ; +0xdb, 0x180014feb\ncall    __RTDynamicCast                                                ; +0xdd, 0x180014fed\nmov     rcx, [rax]                                                     ; +0xe2, 0x180014ff2\nmov     rdx, [rcx+10h]                                                 ; +0xe5, 0x180014ff5\nmov     rcx, rax                                                       ; +0xe9, 0x180014ff9\ncall    rdx                                                            ; +0xec, 0x180014ffc\ncmp     ebp, eax                                                       ; +0xee, 0x180014ffe\njz      short loc_180015020                                            ; +0xf0, 0x180015000\ncmp     ebp, r14d                                                      ; +0xf2, 0x180015002\njb      short loc_18001500B                                            ; +0xf5, 0x180015005\ncmp     ebp, eax                                                       ; +0xf7, 0x180015007\njb      short loc_180015020                                            ; +0xf9, 0x180015009\ninc     ebx                                                            ; +0xfb, 0x18001500b\nadd     rsi, 8                                                         ; +0xfd, 0x18001500d\nmov     r14d, eax                                                      ; +0x101, 0x180015011\ncmp     rsi, r15                                                       ; +0x104, 0x180015014\njbe     short loc_180014FD0                                            ; +0x107, 0x180015017\njmp     short loc_180015020                                            ; +0x109, 0x180015019\nmov     ebx, 0FFFFFFFFh                                                ; +0x10b, 0x18001501b\nmov     rcx, [rdi+270h]                                                ; +0x110, 0x180015020\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x117, 0x180015027\nmov     r15, [rsp+58h+var_28]                                          ; +0x11d, 0x18001502d\nmov     r14, [rsp+58h+var_20]                                          ; +0x122, 0x180015032\nmov     rsi, [rsp+58h+arg_10]                                          ; +0x127, 0x180015037\nmov     rbp, [rsp+58h+arg_8]                                           ; +0x12c, 0x18001503c\ncmp     ebx, eax                                                       ; +0x131, 0x180015041\njnb     short loc_180015085                                            ; +0x133, 0x180015043\nnop     word ptr [rax+rax+00000000h]                                   ; +0x135, 0x180015045\nmov     rcx, [rdi+270h]                                                ; +0x140, 0x180015050\nmov     edx, ebx                                                       ; +0x147, 0x180015057\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x149, 0x180015059\nmov     r8, rax; struct cocos2d::extension::CCTableViewCell *          ; +0x14f, 0x18001505f\nmov     rcx, rdi; this                                                 ; +0x152, 0x180015062\nmov     edx, [rax+148h]                                                ; +0x155, 0x180015065\ninc     edx; unsigned int                                              ; +0x15b, 0x18001506b\ncall    ?_setIndexForCell@CCTableView@extension@cocos2d@@IEAAXIPEAVCCTableViewCell@23@@Z; cocos2d::extension::CCTableView::_setIndexForCell(uint,cocos2d::extension::CCTableViewCell *) ; +0x15d, 0x18001506d\nmov     rcx, [rdi+270h]                                                ; +0x162, 0x180015072\ninc     ebx                                                            ; +0x169, 0x180015079\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x16b, 0x18001507b\ncmp     ebx, eax                                                       ; +0x171, 0x180015081\njb      short loc_180015050                                            ; +0x173, 0x180015083\nmov     rcx, [rdi+280h]                                                ; +0x175, 0x180015085\nmov     r8d, r12d                                                      ; +0x17c, 0x18001508c\nmov     rdx, rdi                                                       ; +0x17f, 0x18001508f\nmov     rax, [rcx]                                                     ; +0x182, 0x180015092\ncall    qword ptr [rax+18h]                                            ; +0x185, 0x180015095\nmov     edx, r12d; unsigned int                                        ; +0x188, 0x180015098\nmov     rcx, rdi; this                                                 ; +0x18b, 0x18001509b\nmov     r8, rax; struct cocos2d::extension::CCTableViewCell *          ; +0x18e, 0x18001509e\nmov     rbx, rax                                                       ; +0x191, 0x1800150a1\ncall    ?_setIndexForCell@CCTableView@extension@cocos2d@@IEAAXIPEAVCCTableViewCell@23@@Z; cocos2d::extension::CCTableView::_setIndexForCell(uint,cocos2d::extension::CCTableViewCell *) ; +0x194, 0x1800150a4\nmov     rdx, rbx; struct cocos2d::extension::CCTableViewCell *         ; +0x199, 0x1800150a9\nmov     rcx, rdi; this                                                 ; +0x19c, 0x1800150ac\ncall    ?_addCellIfNecessary@CCTableView@extension@cocos2d@@IEAAXPEAVCCTableViewCell@23@@Z; cocos2d::extension::CCTableView::_addCellIfNecessary(cocos2d::extension::CCTableViewCell *) ; +0x19f, 0x1800150af\nmov     rcx, rdi; this                                                 ; +0x1a4, 0x1800150b4\ncall    ?_updateCellPositions@CCTableView@extension@cocos2d@@IEAAXXZ; cocos2d::extension::CCTableView::_updateCellPositions(void) ; +0x1a7, 0x1800150b7\nmov     rcx, rdi; this                                                 ; +0x1ac, 0x1800150bc\ncall    ?_updateContentSize@CCTableView@extension@cocos2d@@QEAAXXZ; cocos2d::extension::CCTableView::_updateContentSize(void) ; +0x1af, 0x1800150bf\nmov     r13, [rsp+58h+var_18]                                          ; +0x1b4, 0x1800150c4\nmov     rbx, [rsp+58h+arg_0]                                           ; +0x1b9, 0x1800150c9\nadd     rsp, 48h                                                       ; +0x1be, 0x1800150ce\npop     r12                                                            ; +0x1c2, 0x1800150d2\npop     rdi                                                            ; +0x1c4, 0x1800150d4\nretn                                                                   ; +0x1c5, 0x1800150d5", "xrefs": ["<???> @ 0x180031344", "<???> @ 0x180031384", "<???> @ 0x180032408", "<???> @ 0x18004c6a4"], "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"}