// // GameStatsManager::checkCoinsForLevel from 0x7ba23c to 0x7ba3e8 (428 bytes) // // 2 xrefs: // > GameLevelManager::updateLevelRewards @ 0x704f38 // > @ 0x54978 // // 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 // void GameStatsManager::checkCoinsForLevel(GameStatsManager *a1, GJGameLevel *a2) { int v4; // w19 char *CoinKey; // x22 cocos2d::CCDictionary *m_pendingUserCoins; // x28 char *v7; // x0 unsigned int *v8; // x1 int v9; // w2 std::string v10; // [xsp+80h] [xbp+80h] BYREF if ( a2->m_coins > 0 ) { v4 = a2->m_coinsVerified.random - a2->m_coinsVerified.seed; if ( v4 == 1 ) { do { CoinKey = (char *)GJGameLevel::getCoinKey(a2, v4); if ( GameStatsManager::hasPendingUserCoin(a1, CoinKey) ) { if ( !GameStatsManager::hasUserCoin(a1, CoinKey) ) { GameStatsManager::storeUserCoin(a1, CoinKey); GameStatsManager::incrementStat(a1, "12"); } m_pendingUserCoins = a1->m_pendingUserCoins; sub_D153B8((int)&v10, CoinKey); cocos2d::CCDictionary::removeObjectForKey(m_pendingUserCoins, &v10); v7 = (char *)v10.m_data.m_data - 24; if ( (__int64 *)v10.m_data.m_data - 3 != &qword_124B6B0 ) { if ( &pthread_create ) { v8 = (unsigned int *)((char *)v10.m_data.m_data - 8); do v9 = __ldaxr(v8); while ( __stlxr(v9 - 1, v8) ); } else { v9 = *((_DWORD *)v10.m_data.m_data - 2); *((_DWORD *)v10.m_data.m_data - 2) = v9 - 1; } if ( v9 <= 0 ) operator delete(v7); } } ++v4; } while ( v4 != 4 ); } } }
GD Web Decomp Icon

GD Web Decomp

Raw Source