//
// sub_8AE304 from 0x8ae304 to 0x8ae32c (40 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall sub_8AE304(char a1, unsigned int a2, int a3, int a4)
{
int v4; // r4
unsigned int v7; // r1
*(_BYTE *)(a4 + 31) = a1;
_CF = a2 >= 0x8C;
v7 = a2 - 140;
*(_BYTE *)(v7 + __CFSUB__(a3, v4, _CF) + a3 - (v4 + !_CF) + 9) = v7;
*(_WORD *)(v7 + 4) = v4;
*(_WORD *)(v4 + 40) = (unsigned __int16)&STACK[0x160];
__asm { LDRSHT.W PC, [R9,#0x14] }
}