//
// GameStatsManager::storeRewardState from 0x1401e18e0 to 0x1401e197e (158 bytes)
//
// 3 xrefs:
// > GameLevelManager::onGetGJRewardsCompleted @ 0x140167212
// > GameLevelManager::onGetGJRewardsCompleted @ 0x140167305
// > ??> @ 0x1406cc51c
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
// Hidden C++ exception states: #wind=1
void __fastcall GameStatsManager::storeRewardState(__int64 a1, int a2, unsigned int a3, int a4, __int64 a5)
{
__int64 v6; // rbp
unsigned int v8; // ebx
__int64 v9; // rax
__int64 v10; // rax
_BYTE v11[32]; // [rsp+28h] [rbp-70h] BYREF
__int64 v12; // [rsp+48h] [rbp-50h]
v6 = a2;
v12 = a5;
v8 = 0;
if ( a4 > 0 )
v8 = a4 + (int)sub_14003CF30();
v9 = sub_14003BDB0((__int64)v11, a5);
v10 = GJRewardItem::create(a3, v8, v9);
*(_BYTE *)(v10 + 80) = 1;
*(_DWORD *)(v10 + 64) = v6;
cocos2d::CCDictionary::setObject(*(cocos2d::CCDictionary **)(a1 + 528), (struct cocos2d::CCObject *)v10, v6);
sub_14003A830(a5);
}