//
// sub_8BA978 from 0x8ba978 to 0x8baa64 (236 bytes)
//
// 1 xrefs:
// > sub_8C411C @ 0x8c4b1c
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:03:57 +0000
//
int __fastcall sub_8BA978(int a1, int a2, _QWORD *a3)
{
int v3; // r3
unsigned int v6; // [sp+10h] [bp-Ch] BYREF
if ( *(_QWORD *)(a2 + 8) != 1 )
return 1;
switch ( *(_WORD *)(a2 + 2) )
{
case 4:
case 0xD:
sub_8BF398(a1, a2, &v6);
*a3 = v6;
v3 = 0;
break;
case 0x10:
case 0x12:
v3 = sub_8BF43C(a1, a2, a3);
break;
default:
v3 = 2;
break;
}
return v3;
}