//
// sub_1009A2890 from 0x1009a2890 to 0x1009a2911 (129 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform (idp: pc, 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 12:39:17 +0000
//
__int64 __fastcall sub_1009A2890(__int64 a1, char a2)
{
_DWORD *v2; // r14
__int64 v3; // r15
int HighestChildZ; // ecx
int v5; // eax
__int64 result; // rax
v2 = InfoLayer::create(0, *(_QWORD *)(a1 + 872), 0, 0);
v3 = *(_QWORD *)(cocos2d::CCDirector::sharedDirector() + 272);
HighestChildZ = cocos2d::CCScene::getHighestChildZ(v3);
v5 = 110;
if ( HighestChildZ >= 110 )
v5 = cocos2d::CCScene::getHighestChildZ(v3) + 1;
v2[148] = v5;
result = (*(__int64 (__fastcall **)(_DWORD *))(*(_QWORD *)v2 + 1312LL))(v2);
if ( a2 )
return sub_100894470((__int64)v2);
return result;
}