//
// sub_1006D9848 from 0x1006d9848 to 0x1006d98d8 (144 bytes)
//
// 5 xrefs:
// > sub_1006CF450 @ 0x1006cf884
// > sub_1006CF8D4 @ 0x1006cfe58
// > sub_1006D02E0 @ 0x1006d0a20
// > sub_1006D9DD8 @ 0x1006da400
// > sub_1006E15C0 @ 0x1006e15e0
//
// 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 11:12:30 +0000
//
__int64 __fastcall sub_1006D9848(__int64 a1, __int64 a2, __int64 a3, __int64 *a4)
{
_QWORD *v8; // x0
__int64 v9; // x23
__int64 v10; // x20
sub_1006D1DF8((__int64)a4);
v8 = sub_1006D1F64(a4);
v9 = (__int64)v8;
if ( v8 )
{
if ( sub_1006D1164((__int64)v8, a2) )
v10 = sub_1006D95A8(a1, v9, a3);
else
v10 = 0;
}
else
{
v10 = 0;
}
sub_1006D1EE0((__int64)a4);
return v10;
}