//
// sub_1004ECD00 from 0x1004ecd00 to 0x1004ecd60 (96 bytes)
//
// 2 xrefs:
// > sub_1004ECE90 @ 0x1004ed270
// > sub_1004ECE90 @ 0x1004ed344
//
// 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_1004ECD00(_QWORD *a1, __int64 a2)
{
unsigned int (*v3)(void); // x8
if ( !*a1 )
return 4294967167LL;
v3 = (unsigned int (*)(void))a1[99];
if ( !v3 || v3() == -1 )
return 4294967168LL;
a1[2] = a2;
sub_1004DA2DC((__int64)(a1 + 4));
return 0;
}