//
// sub_77820C from 0x77820c to 0x778252 (70 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
//
_DWORD *__fastcall sub_77820C(unsigned int a1, wchar_t a2)
{
_DWORD *v2; // r4
unsigned int *v6; // r0
unsigned int *v7; // r7
if ( !a1 )
return &unk_ACDDB8;
v6 = sub_777768(a1, 0);
v7 = v6;
v2 = v6 + 3;
if ( a1 == 1 )
v6[3] = a2;
else
wmemset((wchar_t *)v6 + 3, a2, a1);
if ( v7 != (unsigned int *)&unk_ACDDAC )
{
*v7 = a1;
v7[2] = 0;
v7[a1 + 3] = 0;
}
return v2;
}