//
// sub_5D3D0 from 0x5d3d0 to 0x5d414 (68 bytes)
//
// 1 xrefs:
// > sub_5D9B4 @ 0x5da74
//
// This function is hookable on this platform (idp: arm, 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 12:13:52 +0000
//
__int64 __fastcall sub_5D3D0(__int64 result)
{
int v1; // w8
bool v2; // vf
__int64 v3; // x1
__int64 v4; // x19
__int64 v5; // x0
v1 = *(_DWORD *)(result + 424);
v2 = __OFSUB__(v1--, 1);
*(_DWORD *)(result + 424) = v1;
if ( (v1 < 0) ^ v2 | (v1 == 0) )
{
v3 = *(_QWORD *)(result + 416);
v4 = result;
*(_DWORD *)(result + 424) = 0;
if ( v3 )
{
v5 = sub_5D4E8();
result = sub_5D4B8(v5);
*(_QWORD *)(v4 + 416) = 0;
}
}
return result;
}