//
// sub_1005C1C08 from 0x1005c1c08 to 0x1005c1d1c (276 bytes)
//
// 1 xrefs:
// > ??> @ 0x100839eb8
//
// 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_1005C1C08(__int64 a1, __int64 a2)
{
__int64 v3; // x21
__int64 v4; // x0
void *v5; // x19
_BYTE *v6; // x0
__int64 v7; // x21
char **v8; // x0
void *v10; // [xsp+8h] [xbp-38h] BYREF
unsigned int v11; // [xsp+14h] [xbp-2Ch] BYREF
void *v12; // [xsp+18h] [xbp-28h] BYREF
v3 = *(_QWORD *)(a2 + 32);
v12 = nullptr;
if ( (unsigned int)sub_1005C2E2C(&v11, &v12, v3) )
{
v4 = sub_1005BF448(v3, nullptr);
v5 = nullptr;
if ( (int)v4 >= 1 )
{
v6 = sub_100588710(v4, (__int64)"ec_ameth.c", 120);
v5 = v6;
if ( v6 )
{
v10 = v6;
v7 = sub_1005BF448(v3, &v10);
if ( (int)v7 >= 1 )
{
v8 = sub_10058AB9C(0x198u);
if ( (unsigned int)sub_1005F2DF0(a1, v8, v11, v12, v5, v7) )
return 1;
}
}
else
{
v5 = nullptr;
}
}
if ( v11 == 6 )
sub_1005EE6D8(v12);
else
sub_1005FBA78(v12);
if ( v5 )
sub_100588C44(v5);
}
else
{
sub_1005E0E48(16, 216, 16, "ec_ameth.c", 114);
}
return 0;
}