//
// GameLevelManager::setFolderName from 0x3c0398 to 0x3c0402 (106 bytes)
//
// 1 xrefs:
// > SetFolderPopup::setTextPopupClosed @ 0x4a8aa0
//
// 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
//
int __fastcall GameLevelManager::setFolderName(int a1, const char *a2, cocos2d::CCString *a3, int a4)
{
int v5; // r6
cocos2d::CCObject *v6; // r7
cocos2d::CCString *v7; // r0
char *CString; // r0
_BYTE v10[4]; // [sp+8h] [bp-Ch] BYREF
v5 = *(_DWORD *)(a1 + 336);
if ( !a4 )
v5 = *(_DWORD *)(a1 + 332);
v6 = (cocos2d::CCObject *)cocos2d::CCString::create(a3, *(const std::string **)(a1 + 332));
v7 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%i", a2);
CString = (char *)cocos2d::CCString::getCString(v7);
sub_776584((int)v10, CString);
cocos2d::CCDictionary::setObject(v5, v6);
return sub_774008(v10);
}