//
// GJBaseGameLayer::addToObjectsToShow from 0x59f0a8 to 0x59f106 (94 bytes)
//
// 5 xrefs:
// > GJBaseGameLayer::preUpdateVisibility @ 0x5aecfe
// > GJBaseGameLayer::preUpdateVisibility @ 0x5aee90
// > GJBaseGameLayer::preUpdateVisibility @ 0x5af09a
// > GJBaseGameLayer::preUpdateVisibility @ 0x5af0fa
// > GJBaseGameLayer::preUpdateVisibility @ 0x5af4ae
//
// 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:53:15 +0000
//
void __fastcall GJBaseGameLayer::addToObjectsToShow(GJBaseGameLayer *this, GameObject *a2)
{
int v3; // r3
int v4; // r2
char *v5; // r0
_DWORD *v6; // r3
GameObject *v7; // [sp+4h] [bp-4h] BYREF
v7 = a2;
v3 = *((_DWORD *)this + 2730);
v4 = *((_DWORD *)this + 2731);
v7 = a2;
if ( v4 > v3 )
{
*(_DWORD *)(*((_DWORD *)this + 2727) + 4 * v3) = a2;
}
else
{
v5 = (char *)this + 10908;
v6 = *((_DWORD **)v5 + 1);
if ( v6 == *((_DWORD **)this + 2729) )
{
std::vector::__push_back_slow_path((int)v5, &v7);
}
else
{
if ( v6 )
*v6 = a2;
*((_DWORD *)v5 + 1) += 4;
}
++*((_DWORD *)this + 2731);
}
++*((_DWORD *)this + 2730);
}