//
// sub_501F8 from 0x501f8 to 0x50210 (24 bytes)
//
// 2 xrefs:
// > sub_5006E @ 0x50170
// > sub_5032A @ 0x50338
//
// 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 11:40:43 +0000
//
int __fastcall sub_501F8(int a1, _DWORD *a2)
{
int v2; // r2
int result; // r0
v2 = *(_DWORD *)(a1 + 20);
a2[14] = v2;
*(_DWORD *)(a1 + 20) = a2;
if ( v2 )
*(_DWORD *)(v2 + 44) = a2;
a2[11] = 0;
result = a2[6] | 0x20;
a2[6] = result;
return result;
}