//
// sub_1005DEA90 from 0x1005dea90 to 0x1005deac4 (52 bytes)
//
// 8 xrefs:
// > sub_100587F7C @ 0x100588074
// > sub_1005882F4 @ 0x100588380
// > sub_100589560 @ 0x1005895cc
// > sub_100589788 @ 0x100589890
// > sub_1005F660C @ 0x1005f6a40
// > sub_1005FFA90 @ 0x1005ffe60
// > sub_1005FFA90 @ 0x100600730
// > sub_100614A04 @ 0x100614ae0
//
// 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_1005DEA90(__int64 a1, int a2, __int64 a3)
{
__int64 result; // x0
result = 0;
if ( a1 && (a2 & 0x80000000) == 0 )
{
if ( *(_DWORD *)a1 <= a2 )
{
return 0;
}
else
{
*(_QWORD *)(*(_QWORD *)(a1 + 8) + 8LL * a2) = a3;
return a3;
}
}
return result;
}