{"type": "func", "start": 6443580272, "end": 6443580602, "name": "sub_180113B70", "pseudocode": "// \n// sub_180113B70 from 0x180113b70 to 0x180113cba (330 bytes)\n// \n// 4 xrefs:\n// > sub_180114930 @ 0x180114943\n// > <???> @ 0x180191080\n// > <???> @ 0x180191094\n// > <???> @ 0x180201d84\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 10:54:36 +0000\n// \n\n__int64 __fastcall sub_180113B70(__int64 a1)\n{\n  int v1; // edi\n  __int64 result; // rax\n  int v4; // eax\n  int v5; // edi\n  int v6; // r9d\n  __int64 i; // rcx\n  __int64 v8; // rdi\n  __int64 v9; // r11\n  __int64 j; // r10\n  int v11; // eax\n  __int64 v12; // r8\n  int *v13; // rdx\n  int k; // eax\n\n  v1 = *(_DWORD *)(a1 + 36);\n  if ( v1 == -1 )\n    return 28;\n  v4 = *(_DWORD *)(a1 + 8);\n  if ( v1 != v4 )\n    return 0;\n  v5 = 2 * v1;\n  if ( v5 < 4 )\n    v5 = 4;\n  if ( v5 <= v4 || *(_DWORD *)(a1 + 24) != v4 || *(_DWORD *)(a1 + 32) != -1 )\n    return 28;\n  if ( v5 <= (int)abs32(*(_DWORD *)(a1 + 28)) || (result = sub_180114DD0(a1 + 16, (unsigned int)v5), !(_DWORD)result) )\n  {\n    result = sub_1800887F0(a1, v5);\n    if ( !(_DWORD)result )\n    {\n      v6 = 0;\n      for ( i = 0; i < (unsigned int)v5; *(_DWORD *)(*(_QWORD *)a1 + 4 * i++) = -1 )\n        ;\n      if ( *(int *)(a1 + 24) > 0 )\n      {\n        v8 = *(int *)(a1 + 24);\n        v9 = 0;\n        for ( j = 0; ; j += 16 )\n        {\n          v11 = *(_DWORD *)(a1 + 8);\n          if ( !v11 )\n            break;\n          v12 = *(_QWORD *)(a1 + 16);\n          v13 = (int *)(*(_QWORD *)a1 + 4LL * ((v11 - 1) & *(_DWORD *)(j + v12)));\n          for ( k = *v13; *v13 != -1; k = *v13 )\n            v13 = (int *)(16LL * k + v12 + 4);\n          *v13 = v6;\n          ++v9;\n          ++v6;\n          *(_DWORD *)(*(_QWORD *)(a1 + 16) + j + 4) = -1;\n          if ( v9 >= v8 )\n            return 0;\n        }\n        return 28;\n      }\n      return 0;\n    }\n  }\n  return result;\n}", "assembly": "; \n; sub_180113B70 from 0x180113b70 to 0x180113cba (330 bytes)\n; \n; 4 xrefs:\n; > sub_180114930 @ 0x180114943\n; > <???> @ 0x180191080\n; > <???> @ 0x180191094\n; > <???> @ 0x180201d84\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 10:54:36 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x180113b70\npush    rdi                                                            ; +0x5, 0x180113b75\nsub     rsp, 20h                                                       ; +0x6, 0x180113b76\nmov     edi, [rcx+24h]                                                 ; +0xa, 0x180113b7a\nmov     rbx, rcx                                                       ; +0xd, 0x180113b7d\ncmp     edi, 0FFFFFFFFh                                                ; +0x10, 0x180113b80\njnz     short loc_180113B93                                            ; +0x13, 0x180113b83\nlea     eax, [rdi+1Dh]                                                 ; +0x15, 0x180113b85\nmov     rbx, [rsp+28h+arg_8]                                           ; +0x18, 0x180113b88\nadd     rsp, 20h                                                       ; +0x1d, 0x180113b8d\npop     rdi                                                            ; +0x21, 0x180113b91\nretn                                                                   ; +0x22, 0x180113b92\nmov     eax, [rcx+8]                                                   ; +0x23, 0x180113b93\nmov     [rsp+28h+arg_0], rsi                                           ; +0x26, 0x180113b96\ncmp     edi, eax                                                       ; +0x2b, 0x180113b9b\njnz     loc_180113C93                                                  ; +0x2d, 0x180113b9d\nadd     edi, edi                                                       ; +0x33, 0x180113ba3\nmov     ecx, 4                                                         ; +0x35, 0x180113ba5\ncmp     edi, ecx                                                       ; +0x3a, 0x180113baa\ncmovl   edi, ecx                                                       ; +0x3c, 0x180113bac\ncmp     edi, eax                                                       ; +0x3f, 0x180113baf\njle     loc_180113CA5                                                  ; +0x41, 0x180113bb1\ncmp     [rbx+18h], eax                                                 ; +0x47, 0x180113bb7\njnz     loc_180113CA5                                                  ; +0x4a, 0x180113bba\ncmp     dword ptr [rbx+20h], 0FFFFFFFFh                                ; +0x50, 0x180113bc0\njnz     loc_180113CA5                                                  ; +0x54, 0x180113bc4\nmov     eax, [rbx+1Ch]                                                 ; +0x5a, 0x180113bca\ncdq                                                                    ; +0x5d, 0x180113bcd\nxor     eax, edx                                                       ; +0x5e, 0x180113bce\nsub     eax, edx                                                       ; +0x60, 0x180113bd0\ncmp     edi, eax                                                       ; +0x62, 0x180113bd2\njle     short loc_180113BE9                                            ; +0x64, 0x180113bd4\nmov     edx, edi                                                       ; +0x66, 0x180113bd6\nlea     rcx, [rbx+10h]                                                 ; +0x68, 0x180113bd8\ncall    sub_180114DD0                                                  ; +0x6c, 0x180113bdc\ntest    eax, eax                                                       ; +0x71, 0x180113be1\njnz     loc_180113C95                                                  ; +0x73, 0x180113be3\nmov     edx, edi                                                       ; +0x79, 0x180113be9\nmov     rcx, rbx                                                       ; +0x7b, 0x180113beb\ncall    sub_1800887F0                                                  ; +0x7e, 0x180113bee\ntest    eax, eax                                                       ; +0x83, 0x180113bf3\njnz     loc_180113C95                                                  ; +0x85, 0x180113bf5\nxor     r9d, r9d                                                       ; +0x8b, 0x180113bfb\nmov     edx, edi                                                       ; +0x8e, 0x180113bfe\ntest    edi, edi                                                       ; +0x90, 0x180113c00\njz      short loc_180113C22                                            ; +0x92, 0x180113c02\nmov     ecx, r9d                                                       ; +0x94, 0x180113c04\nnop     word ptr [rax+rax+00000000h]                                   ; +0x97, 0x180113c07\nmov     rax, [rbx]                                                     ; +0xa0, 0x180113c10\nmov     dword ptr [rax+rcx*4], 0FFFFFFFFh                              ; +0xa3, 0x180113c13\ninc     rcx                                                            ; +0xaa, 0x180113c1a\ncmp     rcx, rdx                                                       ; +0xad, 0x180113c1d\njl      short loc_180113C10                                            ; +0xb0, 0x180113c20\nmovsxd  rax, dword ptr [rbx+18h]                                       ; +0xb2, 0x180113c22\ntest    eax, eax                                                       ; +0xb6, 0x180113c26\njle     short loc_180113C93                                            ; +0xb8, 0x180113c28\nmov     rdi, rax                                                       ; +0xba, 0x180113c2a\nmov     r11, r9                                                        ; +0xbd, 0x180113c2d\nmov     r10, r9                                                        ; +0xc0, 0x180113c30\nmov     eax, [rbx+8]                                                   ; +0xc3, 0x180113c33\ntest    eax, eax                                                       ; +0xc6, 0x180113c36\njz      short loc_180113CA5                                            ; +0xc8, 0x180113c38\nmov     r8, [rbx+10h]                                                  ; +0xca, 0x180113c3a\ndec     eax                                                            ; +0xce, 0x180113c3e\nmov     ecx, [r10+r8]                                                  ; +0xd0, 0x180113c40\nand     ecx, eax                                                       ; +0xd4, 0x180113c44\nmov     rax, [rbx]                                                     ; +0xd6, 0x180113c46\nmovsxd  rcx, ecx                                                       ; +0xd9, 0x180113c49\nlea     rdx, [rax+rcx*4]                                               ; +0xdc, 0x180113c4c\nmov     eax, [rax+rcx*4]                                               ; +0xe0, 0x180113c50\ncmp     eax, 0FFFFFFFFh                                                ; +0xe3, 0x180113c53\njz      short loc_180113C74                                            ; +0xe6, 0x180113c56\nnop     dword ptr [rax+rax+00000000h]                                  ; +0xe8, 0x180113c58\ncdqe                                                                   ; +0xf0, 0x180113c60\nlea     rdx, [r8+4]                                                    ; +0xf2, 0x180113c62\nshl     rax, 4                                                         ; +0xf6, 0x180113c66\nadd     rdx, rax                                                       ; +0xfa, 0x180113c6a\nmov     eax, [rdx]                                                     ; +0xfd, 0x180113c6d\ncmp     eax, 0FFFFFFFFh                                                ; +0xff, 0x180113c6f\njnz     short loc_180113C60                                            ; +0x102, 0x180113c72\nmov     [rdx], r9d                                                     ; +0x104, 0x180113c74\ninc     r11                                                            ; +0x107, 0x180113c77\nmov     rax, [rbx+10h]                                                 ; +0x10a, 0x180113c7a\ninc     r9d                                                            ; +0x10e, 0x180113c7e\nmov     dword ptr [rax+r10+4], 0FFFFFFFFh                              ; +0x111, 0x180113c81\nadd     r10, 10h                                                       ; +0x11a, 0x180113c8a\ncmp     r11, rdi                                                       ; +0x11e, 0x180113c8e\njl      short loc_180113C33                                            ; +0x121, 0x180113c91\nxor     eax, eax                                                       ; +0x123, 0x180113c93\nmov     rsi, [rsp+28h+arg_0]                                           ; +0x125, 0x180113c95\nmov     rbx, [rsp+28h+arg_8]                                           ; +0x12a, 0x180113c9a\nadd     rsp, 20h                                                       ; +0x12f, 0x180113c9f\npop     rdi                                                            ; +0x133, 0x180113ca3\nretn                                                                   ; +0x134, 0x180113ca4\nmov     rsi, [rsp+28h+arg_0]                                           ; +0x135, 0x180113ca5\nmov     eax, 1Ch                                                       ; +0x13a, 0x180113caa\nmov     rbx, [rsp+28h+arg_8]                                           ; +0x13f, 0x180113caf\nadd     rsp, 20h                                                       ; +0x144, 0x180113cb4\npop     rdi                                                            ; +0x148, 0x180113cb8\nretn                                                                   ; +0x149, 0x180113cb9", "xrefs": ["sub_180114930 @ 0x180114943", "<???> @ 0x180191080", "<???> @ 0x180191094", "<???> @ 0x180201d84"], "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"}