//
// sub_100306BCC from 0x100306bcc to 0x100306c0c (64 bytes)
//
// 1 xrefs:
// > sub_100306AC0 @ 0x100306ba8
//
// 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:03:08 +0000
//
_QWORD *__fastcall sub_100306BCC(_QWORD *result, __int64 a2)
{
__int64 v2; // x10
_QWORD *v3; // x8
__int64 (__fastcall *v4)(_QWORD *); // x2
__int64 v5; // x9
_QWORD *v6; // x0
v2 = result[7];
if ( v2 )
{
v3 = result;
v4 = (__int64 (__fastcall *)(_QWORD *))result[8];
v5 = result[9];
v6 = (_QWORD *)(v2 + (v5 >> 1));
if ( a2 )
{
if ( (v5 & 1) != 0 )
v4 = *(__int64 (__fastcall **)(_QWORD *))(*v6 + (unsigned int)v4);
return (_QWORD *)v4(v6);
}
else
{
if ( (v5 & 1) != 0 )
v4 = *(__int64 (__fastcall **)(_QWORD *))(*v6 + (unsigned int)v4);
return (_QWORD *)((__int64 (__fastcall *)(_QWORD *, _QWORD))v4)(v6, v3[11]);
}
}
return result;
}