//
// GameStatsManager::getItemUnlockState from 0x8e29d0 to 0x8e2ab4 (228 bytes)
//
// 5 xrefs:
// > ItemInfoPopup::init @ 0x8be680
// > GJGarageLayer::setupSpecialPage @ 0x8c02f4
// > GameStatsManager::getItemUnlockStateLite @ 0x8e7b84
// > CharacterColorPage::updateColorMode @ 0xb516d4
// > ??> @ 0xd6c18
//
// 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 12:56:50 +0000
//
__int64 __fastcall GameStatsManager::getItemUnlockState(__int64 a1, unsigned int a2, unsigned int a3)
{
__int64 v3; // x22
__int64 v7; // x20
int v9[2]; // [xsp+48h] [xbp+48h] BYREF
unsigned __int64 v10[3]; // [xsp+50h] [xbp+50h] BYREF
v3 = *(_QWORD *)(a1 + 832);
GameStatsManager::getItemKey(a2, a3, v10);
v7 = cocos2d::CCDictionary::objectForKey(v3, v10);
if ( (v10[0] & 1) != 0 )
{
operator delete((void *)v10[2]);
if ( v7 )
return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v7 + 64LL))(v7);
}
else if ( v7 )
{
return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v7 + 64LL))(v7);
}
v9[0] = a3;
v9[1] = a2;
if ( std::__tree>::__count_unique>(a1 + 888, v9) )
return 3;
else
return 0;
}