//
// GameStatsManager::unlockOnlineChest from 0x52abd4 to 0x52ac52 (126 bytes)
//
// 3 xrefs:
// > GameStatsManager::completedDailyLevel @ 0x52afd4
// > SecretLayer5::claimOnlineReward @ 0x6e4c36
// > NotificationsPage::notificationRewardFinished @ 0x743f92
//
// 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:51:59 +0000
//
GJRewardItem *__fastcall GameStatsManager::unlockOnlineChest(int *a1, int a2)
{
int v4; // r2
int v5; // r3
GJRewardItem *v6; // r6
int v7; // r9
cocos2d::CCObject *v8; // r0
int v10[3]; // [sp+0h] [bp-14h] BYREF
std::string::basic_string(v10, a2);
v6 = GameStatsManager::unlockSpecialChest(a1, (int)v10, v4, v5);
std::string::~string((int)v10);
if ( v6 )
{
v7 = a1[128];
v8 = (cocos2d::CCObject *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%i", (const char *)&dword_0 + 1);
cocos2d::CCDictionary::setObject(v7, v8);
std::string::basic_string(v10, a2);
GameStatsManager::linkSpecialChestUnlocks((unsigned int)a1, (int)v6, (unsigned __int8 *)v10);
std::string::~string((int)v10);
}
return v6;
}