//
// sub_635FE4 from 0x635fe4 to 0x636012 (46 bytes)
//
// 3 xrefs:
// > sub_613B50 @ 0x613bf0
// > sub_645BE0 @ 0x645c3c
// > sub_645C80 @ 0x645ce2
//
// 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
//
_DWORD *__fastcall sub_635FE4(int a1, int a2)
{
_DWORD *result; // r0
int i; // r2
result = off_ABAEAC(8u);
if ( result )
{
*result = a2;
result[1] = 0;
if ( a1 )
{
for ( i = a1; *(_DWORD *)(i + 4); i = *(_DWORD *)(i + 4) )
;
*(_DWORD *)(i + 4) = result;
return (_DWORD *)a1;
}
}
return result;
}