//
// sub_4D0E0 from 0x4d0e0 to 0x4d114 (52 bytes)
//
// 2 xrefs:
// > sub_5B63C @ 0x5b66e
// > sub_5B778 @ 0x5b798
//
// 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
//
int __fastcall sub_4D0E0(int a1, int a2)
{
int result; // r0
if ( *(_BYTE *)(a1 + 336) )
return 0;
*(_DWORD *)a1 = a2;
result = j_FMOD_OS_CriticalSection_Create(a1 + 332, 0);
if ( !result )
{
result = sub_4CC7C(a1 + 8, a1);
if ( !result )
{
*(_BYTE *)(a1 + 336) = 1;
return 0;
}
}
return result;
}