//
// sub_1005933BC from 0x1005933bc to 0x100593444 (136 bytes)
//
// 1 xrefs:
// > sub_100593388 @ 0x1005933ac
//
// 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:08:45 +0000
//
__int64 __usercall sub_1005933BC@(_BYTE *a1@, __int64 a2@)
{
int v2; // w9
__int64 v3; // x11
unsigned int v4; // w10
int v5; // w11
unsigned int v6; // w12
int v7; // w13
unsigned int v8; // w11
char v9; // w9
v4 = ((unsigned __int8)a1[268] * (unsigned int)byte_1009DAE38[v3]) >> 6;
v5 = *(_DWORD *)(a2 + 68);
if ( (((_WORD)v5 - (_WORD)v4) & 0x8000) != 0 )
v6 = *(_DWORD *)(a2 + 68);
else
v6 = v4;
v7 = v5 + v4;
v8 = 64 - v5;
if ( v7 > 64 )
v4 = v8;
if ( v2 < 0 )
v4 = v6;
*(_DWORD *)(a2 + 76) = v4;
v9 = a1[267] + v2;
if ( v9 > 31 )
v9 -= 64;
a1[266] = v9;
*(_BYTE *)(a2 + 60) |= 2u;
return 0;
}