//
// sub_1000307DC from 0x1000307dc to 0x100030864 (136 bytes)
//
// 2 xrefs:
// > GJBaseGameLayer::updateLevelColors @ 0x100278558
// > GJBaseGameLayer::updateLevelColors @ 0x10027857c
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// 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 10:57:30 +0000
//
__int64 __fastcall sub_1000307DC(__int64 a1, __int64 a2, int a3)
{
__int64 v3; // x8
__int64 result; // x0
__int64 v6; // x20
__int64 v7; // x21
__int64 v8; // x0
v3 = 416;
if ( a3 )
v3 = 408;
result = *(_QWORD *)(a1 + v3);
if ( result )
{
v6 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)result + 488LL))(result);
result = sub_1002E757C(v6);
if ( (_DWORD)result )
{
v7 = 0;
do
{
v8 = sub_1002E75A0(v6, v7);
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v8 + 912LL))(v8, a2);
v7 = (unsigned int)(v7 + 1);
result = sub_1002E757C(v6);
}
while ( (unsigned int)v7 < (unsigned int)result );
}
}
return result;
}