//
// sub_1005E4230 from 0x1005e4230 to 0x1005e42c4 (148 bytes)
//
// 7 xrefs:
// > sub_10053BA8C @ 0x10053baa8
// > sub_10053C0F0 @ 0x10053c49c
// > sub_10053C0F0 @ 0x10053c5c8
// > sub_10053C0F0 @ 0x10053c73c
// > sub_10053C9E4 @ 0x10053cba4
// > sub_10053CFF0 @ 0x10053d03c
// > sub_10053D4CC @ 0x10053d81c
//
// 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_1005E4230(char *__b)
{
unsigned int (__fastcall *v2)(char *); // x8
char *v3; // x0
void **v4; // x20
__int64 v5; // x0
if ( __b )
{
if ( *(_QWORD *)__b )
{
v2 = *(unsigned int (__fastcall **)(char *))(*(_QWORD *)__b + 40LL);
if ( v2 && !v2(__b) )
{
LABEL_14:
sub_100588C44(__b);
return;
}
v4 = (void **)(__b + 120);
v3 = *((char **)__b + 15);
if ( v3 )
sub_10058A3A8(v3, *(int *)(*(_QWORD *)__b + 48LL));
}
else
{
v4 = (void **)(__b + 120);
}
if ( *v4 )
sub_100588C44(*v4);
v5 = *((_QWORD *)__b + 1);
if ( v5 )
sub_1005D70C4(v5);
memset(__b, 0, 0xA8u);
goto LABEL_14;
}
}