//
// sub_180057B70 from 0x180057b70 to 0x180057be4 (116 bytes)
//
// 2 xrefs:
// > sub_1800923A0 @ 0x180092433
// > ??> @ 0x1801f8ed4
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 10:53:19 +0000
//
__int64 __fastcall sub_180057B70(_QWORD *a1, _DWORD *a2, char a3)
{
__int64 result; // rax
*((_DWORD *)a1 + 26) = a2[26];
*((_DWORD *)a1 + 32) = a2[32];
if ( !a3
|| (result = sub_1800EBFC0(a1 + 7, *a1, a2 + 14), !(_DWORD)result)
&& (result = sub_1800EBFC0(a1 + 9, *a1, a2 + 18), !(_DWORD)result) )
{
*((_DWORD *)a1 + 27) = a2[27];
*((_DWORD *)a1 + 28) = a2[28];
*((_DWORD *)a1 + 29) = a2[29];
*((_DWORD *)a1 + 30) = a2[30];
return 0;
}
return result;
}