// // GJRateLevelLayer::onCustomButton from 0x452f1c to 0x453038 (284 bytes) // // 0 xrefs: // // 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 GJRateLevelLayer::onCustomButton(GJRateLevelLayer *a1, cocos2d::CCObject *a2) { int v3; // r0 FLAlertLayer *v4; // r4 GameLevelManager *v5; // r0 UploadActionPopup *m_uploadPopup; // r3 std::string v7; // r2 int v8; // [sp+Ch] [bp-14h] UploadPopupDelegate v9; // [sp+18h] [bp-8h] BYREF v3 = a2->getTag(a2); if ( v3 == -4 ) { v8 = (int)a1->getValue(a1, -1); if ( v8 > 0 && a1->m_featureState > 0 ) { v5 = GameLevelManager::sharedState(); if ( GameLevelManager::updateLevelRankAdmin(v5, a1->m_level->m_levelID.random - a1->m_level->m_levelID.seed, v8) ) { GameLevelManager::sharedState()->m_uploadActionDelegate = &a1->UploadActionDelegate; m_uploadPopup = a1->m_uploadPopup; if ( m_uploadPopup ) m_uploadPopup->m_delegate = nullptr; sub_776584((int)&v9, "Updating rank..."); a1->m_uploadPopup = (UploadActionPopup *)UploadActionPopup::create( (UploadActionPopup *)&a1->UploadPopupDelegate, &v9, v7); sub_774008(&v9); a1->m_uploadPopup->show(a1->m_uploadPopup); } } } else if ( v3 == -2 ) { sub_776584((int)&v9, "Do you want to unrate this level?"); v4 = FLAlertLayer::create( (int)&a1->FLAlertLayerProtocol, (int)"Unrate Level", (int)&v9, (int)"Cancel", (int)"Unrate", 380.0); sub_774008(&v9); ButtonSprite::updateBGImage(v4->m_button2, "GJ_button_06.png"); v4->setTag(v4, -3); v4->show(v4); } }
GD Web Decomp Icon

GD Web Decomp

Raw Source