//
// sub_B82C4 from 0xb82c4 to 0xb838c (200 bytes)
//
// 1 xrefs:
// > sub_B86B4 @ 0xb86b8
//
// 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:14:39 +0000
//
__int64 __fastcall sub_B82C4(__int64 a1)
{
__int64 v1; // x8
int v3; // w0
__int64 v4; // x20
__int64 v5; // x8
__int64 v6; // x8
__int64 result; // x0
v1 = *(_QWORD *)(a1 + 168);
*(_DWORD *)(a1 + 548) = 1;
v3 = sub_5FE6C(v1 + 70104);
v4 = 0;
*(_DWORD *)(a1 + 560) = ~v3;
*(_DWORD *)(a1 + 556) = v3;
*(_DWORD *)(a1 + 564) = 572572263 * v3;
*(_DWORD *)(a1 + 568) = -1474208055 * ~v3;
while ( 1 )
{
v5 = *(_QWORD *)(a1 + 232);
if ( v4 >= *(int *)(v5 + 96) )
break;
v6 = *(_QWORD *)(*(_QWORD *)(v5 + 104) + 8 * v4);
if ( *(_DWORD *)v6 == 1 )
{
result = sub_CBDCC(a1, (unsigned int)v4, *(unsigned int *)(v6 + 56));
if ( (_DWORD)result )
return result;
}
else if ( !*(_DWORD *)v6 )
{
result = sub_CBD5C(a1, (unsigned int)v4, *(float *)(v6 + 56));
if ( (_DWORD)result )
return result;
}
++v4;
}
return 0;
}