//
// GameStatsManager::toggleEnableItem from 0x52607c to 0x5260e2 (102 bytes)
//
// 3 xrefs:
// > GJGarageLayer::onToggleItem @ 0x50bc22
// > GameOptionsLayer::onPracticeMusicSync @ 0x5db794
// > GameSettingsLayer::valueDidChange @ 0x711cbc
//
// 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:54 +0000
//
int __fastcall GameStatsManager::toggleEnableItem(int a1, int a2, int a3, int a4)
{
int v6; // r6
cocos2d::CCObject *v7; // r0
_BYTE v9[12]; // [sp+0h] [bp-14h] BYREF
GameStatsManager::getItemKey((GameStatsManager *)v9, a1, a3, a2);
if ( a4 )
{
v6 = *(_DWORD *)(a1 + 508);
v7 = (cocos2d::CCObject *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%i", (const char *)&dword_0 + 1);
cocos2d::CCDictionary::setObject(v6, v7);
}
else
{
cocos2d::CCDictionary::removeObjectForKey(*(cocos2d::CCDictionary **)(a1 + 508));
}
return std::string::~string((int)v9);
}