//
// GameLevelManager::getCompletedGauntletLevels from 0x100548ef0 to 0x100548fa7 (183 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:32:00 +0000
//
__int64 __fastcall GameLevelManager::getCompletedGauntletLevels(__int64 a1)
{
__int64 v1; // rax
unsigned int v2; // ebx
__int64 v3; // r13
const void *v4; // rdi
_DWORD *v5; // rax
__int64 v6; // r12
__int64 v7; // rax
v1 = *(_QWORD *)(a1 + 936);
v2 = 0;
if ( v1 )
{
v3 = *(_QWORD *)(v1 + 56);
if ( v3 )
{
v2 = 0;
do
{
v4 = *(const void **)(v3 + 264);
v3 = *(_QWORD *)(v3 + 288);
if ( v4 )
{
v5 = __dynamic_cast(
v4,
(const struct __class_type_info *)&`typeinfo for'cocos2d::CCObject,
(const struct __class_type_info *)&`typeinfo for'GJGameLevel,
0);
if ( v5 )
{
if ( v5[237] - v5[238] <= 9 && v5[215] - v5[214] == 100 )
{
v6 = (__int64)v5;
v7 = GameStatsManager::sharedState();
v2 += GameStatsManager::hasCompletedLevel(v7, v6);
}
}
}
}
while ( v3 );
}
}
return v2;
}