{"type": "func", "start": 6443276784, "end": 6443277393, "name": "sub_1800C99F0", "pseudocode": "// \n// sub_1800C99F0 from 0x1800c99f0 to 0x1800c9c51 (609 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x18016c5d8\n// > <???> @ 0x1801fe3e8\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:06 +0000\n// \n\n__int64 __fastcall sub_1800C99F0(__int64 a1)\n{\n  __int64 v1; // rdi\n  __int64 v3; // rcx\n  __int64 v4; // rax\n  int v5; // ecx\n  __int64 v6; // rcx\n  float v7; // xmm0_4\n  __int64 v8; // rsi\n  unsigned int v9; // eax\n  int v10; // ecx\n  __int64 v11; // rdx\n  int v12; // eax\n  __int64 result; // rax\n  __int64 v14; // r8\n\n  v1 = *(_QWORD *)(a1 + 40);\n  sub_1801021C0(*(_QWORD *)(a1 + 8), 8);\n  v3 = *(_QWORD *)(a1 + 8);\n  *(_DWORD *)(a1 + 60) &= ~0x80u;\n  sub_180102300(v3, 8);\n  *(_QWORD *)(a1 + 8) = *(_QWORD *)(v1 + 216);\n  *(_BYTE *)(a1 + 136) = 0;\n  *(_QWORD *)(a1 + 144) = 0;\n  *(_DWORD *)(a1 + 152) = 0;\n  _InterlockedAnd((volatile signed __int32 *)(v1 + 88), 0xFFFFFFBF);\n  _InterlockedOr((volatile signed __int32 *)(v1 + 88), 0x800u);\n  if ( *(_QWORD *)(a1 + 72) )\n    _InterlockedOr((volatile signed __int32 *)(v1 + 88), 0x10u);\n  v4 = *(_QWORD *)(v1 + 184);\n  if ( v4 )\n  {\n    _InterlockedAnd((volatile signed __int32 *)(v4 + 88), 0xFFFFFFBF);\n    v5 = *(_DWORD *)(v4 + 404);\n  }\n  else\n  {\n    v5 = *(_DWORD *)(v1 + 404);\n  }\n  *(_DWORD *)(a1 + 76) = v5;\n  v6 = *(_QWORD *)(a1 + 192);\n  *(_QWORD *)(a1 + 156) = 0;\n  v7 = *(float *)(v6 + 104);\n  *(float *)(a1 + 104) = v7;\n  if ( v7 < 100.0 )\n    *(_DWORD *)(a1 + 104) = 1120403456;\n  *(_DWORD *)(a1 + 100) = *(_DWORD *)(v6 + 100);\n  v8 = *(_QWORD *)(v1 + 384);\n  if ( v8 )\n  {\n    if ( (*(_DWORD *)(v1 + 44) & 0x400) != 0\n      || (v9 = *(_DWORD *)(v1 + 36), v9 <= 0x10) && (v10 = 74176, _bittest(&v10, v9))\n      || *(_DWORD *)(v1 + 68) > *(_DWORD *)(v8 + 68) )\n    {\n      _InterlockedAnd((volatile signed __int32 *)(v1 + 88), 0xFFFFFF7F);\n      (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v8 + 280LL))(v8, 2);\n      (*(void (__fastcall **)(__int64, _QWORD, __int64, _QWORD, int))(*(_QWORD *)v8 + 312LL))(\n        v8,\n        0,\n        2,\n        (unsigned int)(*(_DWORD *)(v8 + 68) - 1),\n        2);\n    }\n    else\n    {\n      _InterlockedOr((volatile signed __int32 *)(v1 + 88), 0x88u);\n      v11 = 2;\n      if ( (*(_BYTE *)(a1 + 56) & 6) == 0 )\n        v11 = 1;\n      (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v8 + 280LL))(v8, v11);\n      (*(void (__fastcall **)(__int64, _QWORD, __int64, _QWORD, int))(*(_QWORD *)v8 + 312LL))(\n        v8,\n        *(unsigned int *)(v1 + 76),\n        2,\n        (unsigned int)(*(_DWORD *)(v1 + 76) + *(_DWORD *)(v1 + 80) - 1),\n        2);\n    }\n    v12 = *(_DWORD *)(v8 + 44);\n    *(_QWORD *)(v8 + 184) = v1;\n    *(_DWORD *)(*(_QWORD *)(a1 + 192) + 56LL) = v12;\n    *(_DWORD *)(*(_QWORD *)(a1 + 192) + 88LL) = *(_DWORD *)(v8 + 76);\n    *(_DWORD *)(*(_QWORD *)(a1 + 192) + 92LL) = *(_DWORD *)(v8 + 80);\n    *(_DWORD *)(*(_QWORD *)(a1 + 192) + 96LL) = *(_DWORD *)(v8 + 68);\n    v6 = *(_QWORD *)(a1 + 192);\n  }\n  *(_QWORD *)(v6 + 40) = v8;\n  *(_QWORD *)(*(_QWORD *)(a1 + 192) + 48LL) = 0;\n  *(_DWORD *)(*(_QWORD *)(a1 + 192) + 84LL) = -1;\n  *(_QWORD *)(*(_QWORD *)(a1 + 192) + 24LL) = *(_QWORD *)(a1 + 24);\n  result = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 192) + 40LL))(*(_QWORD *)(a1 + 192));\n  if ( !(_DWORD)result )\n  {\n    sub_1801021C0(*(_QWORD *)(a1 + 8), 10);\n    v14 = *(_QWORD *)(a1 + 8) + 72664LL;\n    *(_QWORD *)(a1 + 184) = a1;\n    *(_QWORD *)(a1 + 176) = *(_QWORD *)(v14 + 8);\n    *(_QWORD *)(a1 + 168) = v14;\n    *(_QWORD *)(v14 + 8) = a1 + 168;\n    **(_QWORD **)(a1 + 176) = a1 + 168;\n    sub_180102300(*(_QWORD *)(a1 + 8), 10);\n    return 0;\n  }\n  return result;\n}", "assembly": "; \n; sub_1800C99F0 from 0x1800c99f0 to 0x1800c9c51 (609 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x18016c5d8\n; > <???> @ 0x1801fe3e8\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:06 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800c99f0\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x1800c99f5\nmov     [rsp+arg_10], rsi                                              ; +0xa, 0x1800c99fa\npush    rdi                                                            ; +0xf, 0x1800c99ff\nsub     rsp, 30h                                                       ; +0x10, 0x1800c9a00\nmov     rdi, [rcx+28h]                                                 ; +0x14, 0x1800c9a04\nmov     rbx, rcx                                                       ; +0x18, 0x1800c9a08\nmov     rcx, [rcx+8]                                                   ; +0x1b, 0x1800c9a0b\nmov     edx, 8                                                         ; +0x1f, 0x1800c9a0f\ncall    sub_1801021C0                                                  ; +0x24, 0x1800c9a14\nmov     rcx, [rbx+8]                                                   ; +0x29, 0x1800c9a19\nmov     edx, 8                                                         ; +0x2d, 0x1800c9a1d\nand     dword ptr [rbx+3Ch], 0FFFFFF7Fh                                ; +0x32, 0x1800c9a22\ncall    sub_180102300                                                  ; +0x39, 0x1800c9a29\nmov     rax, [rdi+0D8h]                                                ; +0x3e, 0x1800c9a2e\nxor     ebp, ebp                                                       ; +0x45, 0x1800c9a35\nmov     [rbx+8], rax                                                   ; +0x47, 0x1800c9a37\nmov     byte ptr [rbx+88h], 0                                          ; +0x4b, 0x1800c9a3b\nmov     [rbx+90h], rbp                                                 ; +0x52, 0x1800c9a42\nmov     [rbx+98h], ebp                                                 ; +0x59, 0x1800c9a49\nlock and dword ptr [rdi+58h], 0FFFFFFBFh                               ; +0x5f, 0x1800c9a4f\nlock or dword ptr [rdi+58h], 800h                                      ; +0x64, 0x1800c9a54\ncmp     [rbx+48h], rbp                                                 ; +0x6c, 0x1800c9a5c\njz      short loc_1800C9A67                                            ; +0x70, 0x1800c9a60\nlock or dword ptr [rdi+58h], 10h                                       ; +0x72, 0x1800c9a62\nmov     rax, [rdi+0B8h]                                                ; +0x77, 0x1800c9a67\ntest    rax, rax                                                       ; +0x7e, 0x1800c9a6e\njz      short loc_1800C9A80                                            ; +0x81, 0x1800c9a71\nlock and dword ptr [rax+58h], 0FFFFFFBFh                               ; +0x83, 0x1800c9a73\nmov     ecx, [rax+194h]                                                ; +0x88, 0x1800c9a78\njmp     short loc_1800C9A86                                            ; +0x8e, 0x1800c9a7e\nmov     ecx, [rdi+194h]                                                ; +0x90, 0x1800c9a80\nmov     [rbx+4Ch], ecx                                                 ; +0x96, 0x1800c9a86\nmov     rcx, [rbx+0C0h]                                                ; +0x99, 0x1800c9a89\nmov     [rbx+9Ch], rbp                                                 ; +0xa0, 0x1800c9a90\nmovss   xmm0, dword ptr [rcx+68h]                                      ; +0xa7, 0x1800c9a97\ncomiss  xmm0, cs:dword_180164634                                       ; +0xac, 0x1800c9a9c\nmovss   dword ptr [rbx+68h], xmm0                                      ; +0xb3, 0x1800c9aa3\njnb     short loc_1800C9AB1                                            ; +0xb8, 0x1800c9aa8\nmov     dword ptr [rbx+68h], 42C80000h                                 ; +0xba, 0x1800c9aaa\nmov     eax, [rcx+64h]                                                 ; +0xc1, 0x1800c9ab1\nmov     [rbx+64h], eax                                                 ; +0xc4, 0x1800c9ab4\nmov     rsi, [rdi+180h]                                                ; +0xc7, 0x1800c9ab7\ntest    rsi, rsi                                                       ; +0xce, 0x1800c9abe\njz      loc_1800C9BB4                                                  ; +0xd1, 0x1800c9ac1\ntest    dword ptr [rdi+2Ch], 400h                                      ; +0xd7, 0x1800c9ac7\njnz     short loc_1800C9B38                                            ; +0xde, 0x1800c9ace\nmov     eax, [rdi+24h]                                                 ; +0xe0, 0x1800c9ad0\ncmp     eax, 10h                                                       ; +0xe3, 0x1800c9ad3\nja      short loc_1800C9AE2                                            ; +0xe6, 0x1800c9ad6\nmov     ecx, 121C0h                                                    ; +0xe8, 0x1800c9ad8\nbt      ecx, eax                                                       ; +0xed, 0x1800c9add\njb      short loc_1800C9B38                                            ; +0xf0, 0x1800c9ae0\nmov     eax, [rsi+44h]                                                 ; +0xf2, 0x1800c9ae2\ncmp     [rdi+44h], eax                                                 ; +0xf5, 0x1800c9ae5\nja      short loc_1800C9B38                                            ; +0xf8, 0x1800c9ae8\nlock or dword ptr [rdi+58h], 88h                                       ; +0xfa, 0x1800c9aea\ntest    byte ptr [rbx+38h], 6                                          ; +0x102, 0x1800c9af2\nmov     rcx, rsi                                                       ; +0x106, 0x1800c9af6\nmov     rax, [rsi]                                                     ; +0x109, 0x1800c9af9\nmov     edx, 2                                                         ; +0x10c, 0x1800c9afc\njnz     short loc_1800C9B08                                            ; +0x111, 0x1800c9b01\nmov     edx, 1                                                         ; +0x113, 0x1800c9b03\ncall    qword ptr [rax+118h]                                           ; +0x118, 0x1800c9b08\nmov     r9d, [rdi+50h]                                                 ; +0x11e, 0x1800c9b0e\nmov     r8d, 2                                                         ; +0x122, 0x1800c9b12\nmov     edx, [rdi+4Ch]                                                 ; +0x128, 0x1800c9b18\ndec     r9d                                                            ; +0x12b, 0x1800c9b1b\nmov     r10, [rsi]                                                     ; +0x12e, 0x1800c9b1e\nadd     r9d, edx                                                       ; +0x131, 0x1800c9b21\nmov     rcx, rsi                                                       ; +0x134, 0x1800c9b24\nmov     [rsp+38h+var_18], 2                                            ; +0x137, 0x1800c9b27\ncall    qword ptr [r10+138h]                                           ; +0x13f, 0x1800c9b2f\njmp     short loc_1800C9B72                                            ; +0x146, 0x1800c9b36\nlock and dword ptr [rdi+58h], 0FFFFFF7Fh                               ; +0x148, 0x1800c9b38\nmov     rax, [rsi]                                                     ; +0x150, 0x1800c9b40\nmov     edx, 2                                                         ; +0x153, 0x1800c9b43\nmov     rcx, rsi                                                       ; +0x158, 0x1800c9b48\ncall    qword ptr [rax+118h]                                           ; +0x15b, 0x1800c9b4b\nmov     r9d, [rsi+44h]                                                 ; +0x161, 0x1800c9b51\nxor     edx, edx                                                       ; +0x165, 0x1800c9b55\nmov     rax, [rsi]                                                     ; +0x167, 0x1800c9b57\ndec     r9d                                                            ; +0x16a, 0x1800c9b5a\nmov     rcx, rsi                                                       ; +0x16d, 0x1800c9b5d\nmov     [rsp+38h+var_18], 2                                            ; +0x170, 0x1800c9b60\nlea     r8d, [rdx+2]                                                   ; +0x178, 0x1800c9b68\ncall    qword ptr [rax+138h]                                           ; +0x17c, 0x1800c9b6c\nmov     eax, [rsi+2Ch]                                                 ; +0x182, 0x1800c9b72\nmov     [rsi+0B8h], rdi                                                ; +0x185, 0x1800c9b75\nmov     rcx, [rbx+0C0h]                                                ; +0x18c, 0x1800c9b7c\nmov     [rcx+38h], eax                                                 ; +0x193, 0x1800c9b83\nmov     rcx, [rbx+0C0h]                                                ; +0x196, 0x1800c9b86\nmov     eax, [rsi+4Ch]                                                 ; +0x19d, 0x1800c9b8d\nmov     [rcx+58h], eax                                                 ; +0x1a0, 0x1800c9b90\nmov     rcx, [rbx+0C0h]                                                ; +0x1a3, 0x1800c9b93\nmov     eax, [rsi+50h]                                                 ; +0x1aa, 0x1800c9b9a\nmov     [rcx+5Ch], eax                                                 ; +0x1ad, 0x1800c9b9d\nmov     rcx, [rbx+0C0h]                                                ; +0x1b0, 0x1800c9ba0\nmov     eax, [rsi+44h]                                                 ; +0x1b7, 0x1800c9ba7\nmov     [rcx+60h], eax                                                 ; +0x1ba, 0x1800c9baa\nmov     rcx, [rbx+0C0h]                                                ; +0x1bd, 0x1800c9bad\nmov     [rcx+28h], rsi                                                 ; +0x1c4, 0x1800c9bb4\nmov     rax, [rbx+0C0h]                                                ; +0x1c8, 0x1800c9bb8\nmov     [rax+30h], rbp                                                 ; +0x1cf, 0x1800c9bbf\nmov     rax, [rbx+0C0h]                                                ; +0x1d3, 0x1800c9bc3\nmov     dword ptr [rax+54h], 0FFFFFFFFh                                ; +0x1da, 0x1800c9bca\nmov     rcx, [rbx+0C0h]                                                ; +0x1e1, 0x1800c9bd1\nmov     rax, [rbx+18h]                                                 ; +0x1e8, 0x1800c9bd8\nmov     [rcx+18h], rax                                                 ; +0x1ec, 0x1800c9bdc\nmov     rcx, [rbx+0C0h]                                                ; +0x1f0, 0x1800c9be0\nmov     rax, [rcx]                                                     ; +0x1f7, 0x1800c9be7\ncall    qword ptr [rax+28h]                                            ; +0x1fa, 0x1800c9bea\ntest    eax, eax                                                       ; +0x1fd, 0x1800c9bed\njnz     short loc_1800C9C3C                                            ; +0x1ff, 0x1800c9bef\nmov     rcx, [rbx+8]                                                   ; +0x201, 0x1800c9bf1\nlea     edx, [rax+0Ah]                                                 ; +0x205, 0x1800c9bf5\ncall    sub_1801021C0                                                  ; +0x208, 0x1800c9bf8\nmov     r8, [rbx+8]                                                    ; +0x20d, 0x1800c9bfd\nlea     rcx, [rbx+0A8h]                                                ; +0x211, 0x1800c9c01\nadd     r8, 11BD8h                                                     ; +0x218, 0x1800c9c08\nmov     [rbx+0B8h], rbx                                                ; +0x21f, 0x1800c9c0f\nmov     edx, 0Ah                                                       ; +0x226, 0x1800c9c16\nmov     rax, [r8+8]                                                    ; +0x22b, 0x1800c9c1b\nmov     [rcx+8], rax                                                   ; +0x22f, 0x1800c9c1f\nmov     [rcx], r8                                                      ; +0x233, 0x1800c9c23\nmov     [r8+8], rcx                                                    ; +0x236, 0x1800c9c26\nmov     rax, [rcx+8]                                                   ; +0x23a, 0x1800c9c2a\nmov     [rax], rcx                                                     ; +0x23e, 0x1800c9c2e\nmov     rcx, [rbx+8]                                                   ; +0x241, 0x1800c9c31\ncall    sub_180102300                                                  ; +0x245, 0x1800c9c35\nxor     eax, eax                                                       ; +0x24a, 0x1800c9c3a\nmov     rbx, [rsp+38h+arg_0]                                           ; +0x24c, 0x1800c9c3c\nmov     rbp, [rsp+38h+arg_8]                                           ; +0x251, 0x1800c9c41\nmov     rsi, [rsp+38h+arg_10]                                          ; +0x256, 0x1800c9c46\nadd     rsp, 30h                                                       ; +0x25b, 0x1800c9c4b\npop     rdi                                                            ; +0x25f, 0x1800c9c4f\nretn                                                                   ; +0x260, 0x1800c9c50", "xrefs": ["<???> @ 0x18016c5d8", "<???> @ 0x1801fe3e8"], "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"}