//
// sub_1800E62C0 from 0x1800e62c0 to 0x1800e6350 (144 bytes)
//
// 2 xrefs:
// > sub_18010BC70 @ 0x18010bccb
// > ??> @ 0x1801ffd8c
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall sub_1800E62C0(__int64 a1, _QWORD *a2, __int64 *a3)
{
__int64 v3; // r11
int v5; // r9d
__int64 v6; // r8
__int64 v7; // rdx
v3 = *(unsigned __int16 *)(a1 + 74216);
v5 = *(_DWORD *)(a1 + 1756) / *(_DWORD *)(a1 + 1752);
v6 = *a2 + 88LL * (unsigned __int16)((v5 + (int)v3 - 1) % v5);
v7 = *a2 + 88 * v3;
*(_BYTE *)v7 = 1;
*(_DWORD *)(v7 + 4) = *(_DWORD *)(v6 + 4);
*(_DWORD *)(v7 + 8) = *(_DWORD *)(v6 + 8);
*(_DWORD *)(v7 + 12) = *(_DWORD *)(v6 + 12);
*(_QWORD *)(v7 + 64) = *(_QWORD *)(v6 + 64);
*(_DWORD *)(v7 + 72) = *(_DWORD *)(v6 + 72);
*(_OWORD *)(v7 + 16) = *(_OWORD *)(v6 + 16);
*(_OWORD *)(v7 + 32) = *(_OWORD *)(v6 + 32);
*(_OWORD *)(v7 + 48) = *(_OWORD *)(v6 + 48);
*a3 = v7;
return 0;
}