//
// sub_1005C0374 from 0x1005c0374 to 0x1005c044c (216 bytes)
//
// 1 xrefs:
// > ??> @ 0x100839de0
//
// 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_1005C0374(__int64 a1, __int64 a2, __int64 a3, __int64 a4)
{
__int64 v6; // x8
__int64 result; // x0
_UNKNOWN **v8; // x0
__int64 v9; // x8
if ( a3 && a4 )
{
if ( sub_1005AAFFC(a2 + 8, a3) )
{
sub_1005AB6E4(a2 + 8, 0);
v6 = sub_1005AAFFC(a2 + 32, a4);
result = 0;
if ( v6 )
{
sub_1005AB6E4(a2 + 32, 0);
v8 = sub_1005AAB2C();
v9 = sub_1005AAFFC(a2 + 56, (__int64)v8);
result = 0;
if ( v9 )
{
sub_1005AB6E4(a2 + 56, 0);
*(_DWORD *)(a2 + 80) = 1;
return 1;
}
}
}
else
{
return 0;
}
}
else
{
sub_1005E0E48(16, 163, 67, "ec2_smpl.c", 396);
return 0;
}
return result;
}