//
// sub_10020BE58 from 0x10020be58 to 0x10020bee0 (136 bytes)
//
// 3 xrefs:
// > GJBaseGameLayer::generatePickupAnimRandVal @ 0x1001e9b08
// > GJBaseGameLayer::generatePickupAnimRandVal @ 0x1001e9b34
// > GJBaseGameLayer::generatePickupAnimRandVal @ 0x1001e9b58
//
// 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
//
char *__fastcall sub_10020BE58(__int64 **a1, int *a2, __int64 a3, _QWORD **a4)
{
__int64 *v6; // x0
char *v7; // x19
__int64 *v8; // x22
__int64 v10; // [xsp+8h] [xbp-28h] BYREF
v6 = sub_10001BC84((__int64)a1, &v10, a2);
v7 = (char *)*v6;
if ( !*v6 )
{
v8 = v6;
v7 = (char *)operator new(0x30u);
*(_QWORD *)(v7 + 28) = **a4;
*((_DWORD *)v7 + 9) = 0;
*((_DWORD *)v7 + 10) = 0;
sub_10000A0F0(a1, v10, v8, v7);
}
return v7;
}