{"type": "func", "start": 6442973088, "end": 6442973244, "name": "sub_18007F7A0", "pseudocode": "// \n// sub_18007F7A0 from 0x18007f7a0 to 0x18007f83c (156 bytes)\n// \n// 2 xrefs:\n// > cocos2d::CCImage::_initWithTiffData @ 0x18007ebed\n// > <???> @ 0x1801bf0e8\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:01 +0000\n// \n\n__int64 __fastcall sub_18007F7A0(__int64 a1, char *a2, unsigned __int64 a3)\n{\n  __int64 v3; // r14\n  unsigned __int64 v4; // rsi\n  int v7; // ecx\n  unsigned int v8; // ebx\n\n  v3 = 0;\n  v4 = a3;\n  if ( !a3 )\n    return v3;\n  v7 = *(_DWORD *)(a1 + 12);\n  while ( 1 )\n  {\n    v8 = 0x80000000;\n    if ( v4 < 0x80000000 )\n      v8 = v4;\n    if ( (signed int)(v7 + v8) > *(_DWORD *)(a1 + 8) )\n      break;\n    memcpy(a2, (const void *)(*(_QWORD *)a1 + v7), v8);\n    *(_DWORD *)(a1 + 12) += v8;\n    a2 += v8;\n    v7 = *(_DWORD *)(a1 + 12);\n    v3 += v8;\n    v4 -= v8;\n    if ( !v4 )\n      return v3;\n  }\n  return 0;\n}", "assembly": "; \n; sub_18007F7A0 from 0x18007f7a0 to 0x18007f83c (156 bytes)\n; \n; 2 xrefs:\n; > cocos2d::CCImage::_initWithTiffData @ 0x18007ebed\n; > <???> @ 0x1801bf0e8\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:01 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x18007f7a0\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x18007f7a5\nmov     [rsp+arg_10], rsi                                              ; +0xa, 0x18007f7aa\nmov     [rsp+arg_18], rdi                                              ; +0xf, 0x18007f7af\npush    r12                                                            ; +0x14, 0x18007f7b4\npush    r14                                                            ; +0x16, 0x18007f7b6\npush    r15                                                            ; +0x18, 0x18007f7b8\nsub     rsp, 20h                                                       ; +0x1a, 0x18007f7ba\nxor     r14d, r14d                                                     ; +0x1e, 0x18007f7be\nmov     rsi, r8                                                        ; +0x21, 0x18007f7c1\nmov     r15, rdx                                                       ; +0x24, 0x18007f7c4\nmov     rbp, rcx                                                       ; +0x27, 0x18007f7c7\ntest    r8, r8                                                         ; +0x2a, 0x18007f7ca\njz      short loc_18007F816                                            ; +0x2d, 0x18007f7cd\nmov     ecx, [rcx+0Ch]                                                 ; +0x2f, 0x18007f7cf\nmov     r12d, 80000000h                                                ; +0x32, 0x18007f7d2\nnop     dword ptr [rax+rax+00000000h]                                  ; +0x38, 0x18007f7d8\ncmp     rsi, r12                                                       ; +0x40, 0x18007f7e0\nmov     ebx, r12d                                                      ; +0x43, 0x18007f7e3\ncmovb   ebx, esi                                                       ; +0x46, 0x18007f7e6\nlea     eax, [rcx+rbx]                                                 ; +0x49, 0x18007f7e9\ncmp     eax, [rbp+8]                                                   ; +0x4c, 0x18007f7ec\njg      short loc_18007F838                                            ; +0x4f, 0x18007f7ef\nmovsxd  rdx, ecx                                                       ; +0x51, 0x18007f7f1\nmov     rcx, r15; void *                                               ; +0x54, 0x18007f7f4\nadd     rdx, [rbp+0]; Src                                              ; +0x57, 0x18007f7f7\nmov     r8d, ebx; Size                                                 ; +0x5b, 0x18007f7fb\nmov     edi, ebx                                                       ; +0x5e, 0x18007f7fe\ncall    memcpy                                                         ; +0x60, 0x18007f800\nadd     [rbp+0Ch], ebx                                                 ; +0x65, 0x18007f805\nadd     r15, rdi                                                       ; +0x68, 0x18007f808\nmov     ecx, [rbp+0Ch]                                                 ; +0x6b, 0x18007f80b\nadd     r14, rdi                                                       ; +0x6e, 0x18007f80e\nsub     rsi, rdi                                                       ; +0x71, 0x18007f811\njnz     short loc_18007F7E0                                            ; +0x74, 0x18007f814\nmov     rax, r14                                                       ; +0x76, 0x18007f816\nmov     rbx, [rsp+38h+arg_0]                                           ; +0x79, 0x18007f819\nmov     rbp, [rsp+38h+arg_8]                                           ; +0x7e, 0x18007f81e\nmov     rsi, [rsp+38h+arg_10]                                          ; +0x83, 0x18007f823\nmov     rdi, [rsp+38h+arg_18]                                          ; +0x88, 0x18007f828\nadd     rsp, 20h                                                       ; +0x8d, 0x18007f82d\npop     r15                                                            ; +0x91, 0x18007f831\npop     r14                                                            ; +0x93, 0x18007f833\npop     r12                                                            ; +0x95, 0x18007f835\nretn                                                                   ; +0x97, 0x18007f837\nxor     eax, eax                                                       ; +0x98, 0x18007f838\njmp     short loc_18007F819                                            ; +0x9a, 0x18007f83a", "xrefs": ["cocos2d::CCImage::_initWithTiffData @ 0x18007ebed", "<???> @ 0x1801bf0e8"], "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"}