{"type": "func", "start": 6443165856, "end": 6443166005, "name": "cocos2d::CCTileMapAtlas::calculateItemsToRender", "pseudocode": "// \n// cocos2d::CCTileMapAtlas::calculateItemsToRender from 0x1800ae8a0 to 0x1800ae935 (149 bytes)\n// \n// 3 xrefs:\n// > cocos2d::CCTileMapAtlas::initWithTileFile @ 0x1800aea73\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801c22f8\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:18 +0000\n// \n\nvoid __fastcall cocos2d::CCTileMapAtlas::calculateItemsToRender(cocos2d::CCTileMapAtlas *this)\n{\n  __int64 v1; // r9\n  int v2; // ebx\n  __int16 v3; // r10\n  int v4; // eax\n  __int16 i; // dx\n\n  v1 = *((_QWORD *)this + 51);\n  *((_DWORD *)this + 106) = 0;\n  v2 = 0;\n  v3 = *(_WORD *)(v1 + 6);\n  if ( v3 > 0 )\n  {\n    do\n    {\n      v4 = 0;\n      for ( i = v3; v4 < *(__int16 *)(v1 + 8); v3 = i )\n      {\n        i = v3;\n        if ( (unsigned __int8)*(_WORD *)(3LL * (v2 + v4 * v3) + *(_QWORD *)(v1 + 16)) )\n        {\n          ++*((_DWORD *)this + 106);\n          i = *(_WORD *)(v1 + 6);\n        }\n        ++v4;\n      }\n      ++v2;\n      v3 = i;\n    }\n    while ( v2 < i );\n  }\n}", "assembly": "; \n; cocos2d::CCTileMapAtlas::calculateItemsToRender from 0x1800ae8a0 to 0x1800ae935 (149 bytes)\n; \n; 3 xrefs:\n; > cocos2d::CCTileMapAtlas::initWithTileFile @ 0x1800aea73\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801c22f8\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:18 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x1800ae8a0\nmov     [rsp+arg_10], rdi                                              ; +0x5, 0x1800ae8a5\nmov     r9, [rcx+198h]                                                 ; +0xa, 0x1800ae8aa\nxor     edi, edi                                                       ; +0x11, 0x1800ae8b1\nmov     [rcx+1A8h], edi                                                ; +0x13, 0x1800ae8b3\nmov     r11, rcx                                                       ; +0x19, 0x1800ae8b9\nmov     ebx, edi                                                       ; +0x1c, 0x1800ae8bc\nmovzx   r10d, word ptr [r9+6]                                          ; +0x1e, 0x1800ae8be\ncmp     di, r10w                                                       ; +0x23, 0x1800ae8c3\njge     short loc_1800AE92A                                            ; +0x27, 0x1800ae8c7\nnop     dword ptr [rax+00000000h]                                      ; +0x29, 0x1800ae8c9\nmov     eax, edi                                                       ; +0x30, 0x1800ae8d0\nmovzx   edx, r10w                                                      ; +0x32, 0x1800ae8d2\ncmp     di, [r9+8]                                                     ; +0x36, 0x1800ae8d6\njge     short loc_1800AE91D                                            ; +0x3b, 0x1800ae8db\nnop     dword ptr [rax]                                                ; +0x3d, 0x1800ae8dd\nmovsx   ecx, r10w                                                      ; +0x40, 0x1800ae8e0\nimul    ecx, eax                                                       ; +0x44, 0x1800ae8e4\nadd     ecx, ebx                                                       ; +0x47, 0x1800ae8e7\nmovsxd  rcx, ecx                                                       ; +0x49, 0x1800ae8e9\nlea     rdx, [rcx+rcx*2]                                               ; +0x4c, 0x1800ae8ec\nmov     rcx, [r9+10h]                                                  ; +0x50, 0x1800ae8f0\nmovzx   r8d, word ptr [rdx+rcx]                                        ; +0x54, 0x1800ae8f4\nmovzx   edx, r10w                                                      ; +0x59, 0x1800ae8f9\ntest    r8b, r8b                                                       ; +0x5d, 0x1800ae8fd\njz      short loc_1800AE90E                                            ; +0x60, 0x1800ae900\ninc     dword ptr [r11+1A8h]                                           ; +0x62, 0x1800ae902\nmovzx   edx, word ptr [r9+6]                                           ; +0x69, 0x1800ae909\nmovsx   ecx, word ptr [r9+8]                                           ; +0x6e, 0x1800ae90e\ninc     eax                                                            ; +0x73, 0x1800ae913\nmovzx   r10d, dx                                                       ; +0x75, 0x1800ae915\ncmp     eax, ecx                                                       ; +0x79, 0x1800ae919\njl      short loc_1800AE8E0                                            ; +0x7b, 0x1800ae91b\ninc     ebx                                                            ; +0x7d, 0x1800ae91d\nmovsx   eax, dx                                                        ; +0x7f, 0x1800ae91f\nmovzx   r10d, dx                                                       ; +0x82, 0x1800ae922\ncmp     ebx, eax                                                       ; +0x86, 0x1800ae926\njl      short loc_1800AE8D0                                            ; +0x88, 0x1800ae928\nmov     rbx, [rsp+arg_8]                                               ; +0x8a, 0x1800ae92a\nmov     rdi, [rsp+arg_10]                                              ; +0x8f, 0x1800ae92f\nretn                                                                   ; +0x94, 0x1800ae934", "xrefs": ["cocos2d::CCTileMapAtlas::initWithTileFile @ 0x1800aea73", "<???> @ 0x18014cf68", "<???> @ 0x1801c22f8"], "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"}