// // GameLevelManager::onGetLevelSaveDataCompleted from 0x4c1c04 to 0x4c1d32 (302 bytes) // // 1 xrefs: // > GameLevelManager::handleIt @ 0x4dae2a // // 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:50:24 +0000 // unsigned int __fastcall GameLevelManager::onGetLevelSaveDataCompleted( GameLevelManager *a1, unsigned __int8 *a2, int a3) { const char *v5; // r1 _BOOL4 v6; // r7 unsigned int result; // r0 int v8; // r7 const char *v9; // r0 int v10; // r3 cocos2d::CCArray *v11; // r7 unsigned int i; // r5 cocos2d::CCString *v13; // r0 const char *v14; // r10 cocos2d::CCString *v15; // r0 int v16; // r11 GJGameLevel *SavedLevel; // r0 GJGameLevel *v18; // r10 int v19[3]; // [sp+Ch] [bp-20h] BYREF int v20[3]; // [sp+18h] [bp-14h] BYREF if ( (*(_BYTE *)a3 & 1) != 0 ) v5 = *(const char **)(a3 + 8); else v5 = (const char *)(a3 + 1); GameLevelManager::removeDLFromActive(a1, v5); memset(v20, 0, sizeof(v20)); std::string::__init(v20, "-1", 2u); v6 = sub_4A9CC4(a2, (unsigned __int8 *)v20); result = std::string::~string((int)v20); if ( !v6 ) { v8 = *a2; v9 = (v8 & 1) != 0 ? *((const char **)a2 + 2) : (const char *)(a2 + 1); result = strlen(v9); if ( result > 0x28 ) { if ( (v8 & 1) != 0 ) v10 = *((_DWORD *)a2 + 1); else v10 = v8 >> 1; std::string::basic_string(v19, a2, 0x14u, v10 - 40); cocos2d::ZipUtils::decompressString(v20, v19, 0, 11); v11 = sub_4C1A88(v20, ","); for ( i = 0; i + 1 < cocos2d::CCArray::count(v11); i += 2 ) { v13 = (cocos2d::CCString *)cocos2d::CCArray::stringAtIndex(v11, i); v14 = (const char *)cocos2d::CCString::intValue(v13); v15 = (cocos2d::CCString *)cocos2d::CCArray::stringAtIndex(v11, i + 1); v16 = cocos2d::CCString::intValue(v15); if ( (unsigned int)(v16 - 1) <= 9 ) { SavedLevel = (GJGameLevel *)GameLevelManager::getSavedLevel(a1, v14); v18 = SavedLevel; if ( SavedLevel ) { GJGameLevel::setStars(SavedLevel, v16); GJGameLevel::setDemon(v18, v16 == 10); GameLevelManager::verifyLevelState(a1, v18); GameLevelManager::updateLevelRewards(a1, v18); } } } std::string::~string((int)v20); return std::string::~string((int)v19); } } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source