//
// sub_631FD0 from 0x631fd0 to 0x632060 (144 bytes)
//
// 4 xrefs:
// > sub_6320DC @ 0x632128
// > sub_6320DC @ 0x63241c
// > sub_6320DC @ 0x63243c
// > sub_DFDF6C @ 0xe003b0
//
// 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:50:12 +0000
//
__int64 __fastcall sub_631FD0(__int64 a1, char a2, char a3, __int64 a4)
{
__int64 result; // x0
if ( (*(_DWORD *)(a4 + 120) & 3) == 0 || a3 && a2 )
return 0;
result = (unsigned __int8)sub_E10BA0(*(_QWORD *)(a1 + 96), 1);
if ( !(_BYTE)result || *(_QWORD *)(a1 + 1080) == 1 || (*(_DWORD *)(a1 + 1072) & 0xFFFFFFFB) != 1 )
{
if ( (unsigned __int8)sub_E10BA0(*(_QWORD *)(a1 + 96), 2) )
return *(_QWORD *)(a1 + 1080) > 2LL;
return 0;
}
return result;
}