// // LevelPage::updateDynamicPage from 0x14031a8b0 to 0x14031bcd1 (5153 bytes) // // 2 xrefs: // > LevelSelectLayer::updatePageWithObject @ 0x14031921e // > @ 0x1406d4af0 // // 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 // // Hidden C++ exception states: #wind=12 void LevelPage::updateDynamicPage(LevelPage *a1, GJGameLevel *a2) { float v2; // xmm3_4 cocos2d::CCParticleSystemQuad *v5; // r14 GJGameLevel *m_level; // rcx unsigned int i; // ebx struct cocos2d::CCObject *v8; // rax __int64 v9; // rcx cocos2d::CCDirector *v10; // rax int v11; // ecx unsigned int j; // ebx struct cocos2d::CCObject *v13; // rax __int64 v14; // rdx unsigned int k; // ebx struct cocos2d::CCObject *v16; // rax __int64 v17; // rdx float v18; // xmm1_4 float m_progressWidth; // xmm3_4 cocos2d::CCSprite *m_normalProgressBar; // rax cocos2d::CCSprite_vtbl *v21; // rbx const cocos2d::CCRect *v22; // rax cocos2d::CCSprite *m_practiceProgressBar; // rax cocos2d::CCSprite_vtbl *v24; // rbx const cocos2d::CCRect *v25; // rax cocos2d::CCString *v26; // rax const char *CString; // rax cocos2d::CCString *v28; // rax const char *v29; // rax GameStatsManager *v30; // rcx const char *v31; // rdx cocos2d::CCLabelBMFont *m_nameLabel; // rcx cocos2d::CCLabelBMFont_vtbl *v33; // rbx GJDifficulty m_difficulty; // ecx int v35; // r13d GJDifficulty v36; // edx cocos2d::CCString *v37; // rax const char *v38; // rbx cocos2d::CCSprite *m_difficultySprite; // rcx cocos2d::CCSprite_vtbl *v40; // rdi cocos2d::CCSpriteFrameCache *v41; // rax struct cocos2d::CCSpriteFrame *v42; // rax cocos2d::CCSprite *v43; // rbx double v44; // xmm0_8 float v45; // xmm6_4 const cocos2d::CCSize *v46; // rbx cocos2d::CCSprite_vtbl *v47; // rbx double v48; // xmm0_8 const cocos2d::CCPoint *v49; // rax cocos2d::CCLabelBMFont_vtbl *v50; // rbx const cocos2d::CCPoint *v51; // rax const cocos2d::CCPoint *v52; // rax cocos2d::CCLabelProtocol_vtbl *v53; // rbx cocos2d::CCString *v54; // rax const char *v55; // rax GameStatsManager *v56; // rcx bool hasCompletedStarLevel; // al cocos2d::CCRGBAProtocol *v58; // rcx __int16 *v59; // rdx GameStatsManager *v60; // rbx GJGameLevel *v61; // rax __int64 v62; // rdx cocos2d::CCString *v63; // rax const char *v64; // rcx const char *v65; // rax bool hasSecretCoin; // si __int64 v67; // rcx struct cocos2d::CCObject *v68; // r12 cocos2d::CCObject_vtbl *v69; // rdi const char *v70; // rbx cocos2d::CCSpriteFrameCache *v71; // rax struct cocos2d::CCSpriteFrame *v72; // rax __int16 *v73; // rdx int v74; // edi int v75; // r12d unsigned int v76; // r14d struct cocos2d::CCObject *v77; // rax struct cocos2d::CCSprite *v78; // r14 float v79; // xmm0_4 cocos2d::CCSprite_vtbl *v80; // rbx const cocos2d::CCPoint *v81; // rax struct cocos2d::CCSprite *v82; // rsi float v83; // xmm0_4 cocos2d::CCSprite_vtbl *v84; // rbx const cocos2d::CCPoint *v85; // rax cocos2d::CCString *v86; // rax const char *v87; // rax struct cocos2d::CCLabelBMFont *v88; // rdi float v89; // xmm0_4 cocos2d::CCLabelBMFont_vtbl *v90; // rbx __int64 v91; // rax float v92; // xmm0_4 __int64 v93; // rax GameStatsManager *v94; // rcx int BaseCurrencyForLevel; // edi GameStatsManager *v96; // rcx int AwardedCurrencyForLevel; // ebx cocos2d::CCString *v98; // rax const char *v99; // rax float v100; // xmm0_4 cocos2d::CCLabelBMFont_vtbl *v101; // rbx __int64 v102; // rax float v103; // xmm0_4 cocos2d::CCLabelBMFont_vtbl *v104; // rbx const cocos2d::CCPoint *v105; // rax cocos2d::CCSprite_vtbl *v106; // rbx float width; // xmm6_4 double v108; // xmm0_8 float v109; // xmm7_4 const cocos2d::CCPoint *v110; // rax bool v111; // zf cocos2d::CCArray *m_progressObjects; // rcx unsigned int v113; // ebx struct cocos2d::CCObject *v114; // rax CCLightFlash *v115; // rsi CCMenuItemSpriteExtra *v116; // rbx struct cocos2d::CCMenu *v117; // rdi float v118; // xmm0_4 cocos2d::CCMenu_vtbl *v119; // rbx double v120; // xmm0_8 const cocos2d::CCPoint *v121; // rax struct cocos2d::CCSprite *v122; // rdi cocos2d::CCSprite_vtbl *v123; // rbx float *v124; // rax __int64 v125; // rax float v126; // xmm0_4 const struct cocos2d::CCPoint *v127; // rax struct cocos2d::CCMoveBy *v128; // rax struct cocos2d::CCEaseInOut *v129; // rbx const struct cocos2d::CCPoint *v130; // rax struct cocos2d::CCMoveBy *v131; // rax struct cocos2d::CCEaseInOut *v132; // rax struct cocos2d::CCSequence *v133; // rax struct cocos2d::CCRepeatForever *v134; // rax cocos2d::ccColor3B *v135; // r8 cocos2d::CCParticleSystemQuad *v136; // r12 double v137; // xmm0_8 cocos2d::CCParticleSystemQuad_vtbl *v138; // rbx float *v139; // rax const cocos2d::CCPoint *v140; // rax _WORD *v141; // rax cocos2d::CCParticleSystemQuad *v142; // rdi double v143; // xmm0_8 cocos2d::CCParticleSystemQuad_vtbl *v144; // rbx float *v145; // rax const cocos2d::CCPoint *v146; // rax double v147; // xmm0_8 cocos2d::CCParticleSystemQuad_vtbl *v148; // rbx float *v149; // rax const cocos2d::CCPoint *v150; // rax __int64 v151; // rbx struct cocos2d::CCObject *v152; // rax struct cocos2d::CCLabelBMFont *v153; // rdi float v154; // xmm0_4 cocos2d::CCLabelBMFont_vtbl *v155; // rbx const cocos2d::CCPoint *v156; // rax GameObject *m_coinObject; // rcx GJGameLevel *v158; // rdx float v159; // [rsp+28h] [rbp-E0h] __int16 v160; // [rsp+38h] [rbp-D0h] BYREF char v161; // [rsp+3Ah] [rbp-CEh] cocos2d::CCRect v162; // [rsp+40h] [rbp-C8h] BYREF __int16 v163; // [rsp+50h] [rbp-B8h] BYREF char v164; // [rsp+52h] [rbp-B6h] __int16 v165; // [rsp+54h] [rbp-B4h] __int16 v166; // [rsp+58h] [rbp-B0h] BYREF char v167; // [rsp+5Ah] [rbp-AEh] void *v168; // [rsp+60h] [rbp-A8h] BYREF float v169; // [rsp+68h] [rbp-A0h] _QWORD v170[3]; // [rsp+70h] [rbp-98h] BYREF __int64 v171; // [rsp+88h] [rbp-80h] unsigned __int64 v172; // [rsp+90h] [rbp-78h] __int128 v173; // [rsp+98h] [rbp-70h] BYREF __int64 v174; // [rsp+A8h] [rbp-60h] __int64 v175; // [rsp+B0h] [rbp-58h] __int128 v176; // [rsp+B8h] [rbp-50h] BYREF __int64 v177; // [rsp+C8h] [rbp-40h] __int64 v178; // [rsp+D0h] [rbp-38h] cocos2d::ParticleStruct v179; // [rsp+D8h] [rbp-30h] BYREF cocos2d::ParticleStruct v180; // [rsp+208h] [rbp+100h] BYREF cocos2d::ParticleStruct v181; // [rsp+338h] [rbp+230h] BYREF v5 = nullptr; if ( a1->m_isBusy ) return; m_level = a1->m_level; if ( m_level ) { if ( a2->m_levelID.random - a2->m_levelID.seed == m_level->m_levelID.random - m_level->m_levelID.seed ) return; cocos2d::CCObject::release(m_level); a1->m_level = nullptr; } for ( i = 0; i < cocos2d::CCArray::count(a1->m_dynamicObjects); ++i ) { v8 = cocos2d::CCArray::objectAtIndex(a1->m_dynamicObjects, i); ((void (__fastcall *)(struct cocos2d::CCObject *))v8->__vftable[6].setTag)(v8); } cocos2d::CCArray::removeAllObjects(a1->m_dynamicObjects); a1->m_secretDoor = nullptr; a1->m_level = a2; cocos2d::CCObject::retain(a2); v10 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v9); cocos2d::CCDirector::getWinSize(v10); v11 = a1->m_level->m_levelID.random - a1->m_level->m_levelID.seed; if ( v11 <= 0 ) { v111 = v11 == -2; m_progressObjects = a1->m_progressObjects; if ( !v111 ) { if ( cocos2d::CCArray::count(m_progressObjects) ) { do { v152 = cocos2d::CCArray::objectAtIndex(a1->m_progressObjects, (unsigned int)v5); ((void (__fastcall *)(struct cocos2d::CCObject *, _QWORD))v152->__vftable[4].update)(v152, 0); LODWORD(v5) = (_DWORD)v5 + 1; } while ( (unsigned int)v5 < cocos2d::CCArray::count(a1->m_progressObjects) ); } v153 = cocos2d::CCLabelBMFont::create("Coming Soon!", (const char *)&qword_14052A4D8); v154 = ((float (__fastcall *)(LevelPage *, struct cocos2d::CCLabelBMFont *))a1->addChild_1)(a1, v153); v155 = v153->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCPoint::CCPoint(v154, v169 * 0.5); v155->setPosition_0(v153, v156); cocos2d::CCArray::addObject(a1->m_dynamicObjects, v153); LevelPage::addSecretDoor(a1); goto LABEL_76; } v113 = 0; if ( cocos2d::CCArray::count(m_progressObjects) ) { do { v114 = cocos2d::CCArray::objectAtIndex(a1->m_progressObjects, v113); ((void (__fastcall *)(struct cocos2d::CCObject *, _QWORD))v114->__vftable[4].update)(v114, 0); ++v113; } while ( v113 < cocos2d::CCArray::count(a1->m_progressObjects) ); } v115 = (CCLightFlash *)cocos2d::CCSprite::createWithSpriteFrameName("theTowerDoor_001.png"); v162.origin = (cocos2d::CCPoint)operator new(0x208u); v116 = CCMenuItemSpriteExtra::CCMenuItemSpriteExtra(*(CCMenuItemSpriteExtra **)&v162.origin); if ( v116 ) { if ( CCMenuItemSpriteExtra::init(v116, v115, nullptr, a1, (cocos2d::SEL_MenuHandler *)LevelPage::onTheTower) ) { cocos2d::CCObject::autorelease(v116); LABEL_62: v117 = cocos2d::CCMenu::createWithItem(v116); v118 = ((float (__fastcall *)(LevelPage *, struct cocos2d::CCMenu *))a1->addChild_1)(a1, v117); v119 = v117->cocos2d::CCLayerRGBA::cocos2d::CCLayer::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v120 = cocos2d::CCPoint::CCPoint(v118, v169 * 0.5); v119->setPosition_0(v117, v121); cocos2d::CCArray::addObject(a1->m_dynamicObjects, v117); v122 = cocos2d::CCSprite::createWithSpriteFrameName("theTowerLabel_001.png"); v115->addChild_1(v115, v122); v123 = v122->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v115->getContentSize(v115); v124 = (float *)v115->getContentSize(v115); cocos2d::CCPoint::CCPoint(*(float *)&v120, *v124 * 0.5); v126 = ((float (__fastcall *)(struct cocos2d::CCSprite *, __int64))v123->setPosition_0)(v122, v125); cocos2d::CCPoint::CCPoint(v126, 0.0); v128 = cocos2d::CCMoveBy::create(2.5, v127); v129 = cocos2d::CCEaseInOut::create(v128, 1.8); cocos2d::CCPoint::CCPoint(2.5, 0.0); v131 = cocos2d::CCMoveBy::create(2.5, v130); v132 = cocos2d::CCEaseInOut::create(v131, 1.8); v133 = cocos2d::CCSequence::create(v129, v132, 0); v134 = cocos2d::CCRepeatForever::create(v133); cocos2d::CCNode::runAction(v115, (cocos2d::CCPoint)v134, v135, v2, v159); *(_OWORD *)&v170[1] = 0; v170[1] = sub_14003AA10(0xC0u); v171 = 189; v172 = 191; qmemcpy( (void *)v170[1], "30a-1a2.2a0.48a11a90a180a29a0a11a0a0a0a0a0a0a0a5a1a0a0a0.0745098a0a0a0a0.611765a0a1a0a2a1a0a0a0a0a0.937255a0a1" "a0a1a0a0.54a0a0.57a0a56a0a11a0a-25a17a1a2a1a0a0a1a0a0a0a0a0a0a0a0a0a0a0a0a0a0a", 188); *(_WORD *)(v170[1] + 188LL) = (unsigned __int8)a30a1a22a048a11[188]; if ( v171 ) { sub_140063B90((__int64)&v179); GameToolbox::particleStringToStruct(&v170[1], (__int64)&v179); v136 = GameToolbox::particleFromStruct(&v179, nullptr, 0); sub_14003A830((__int64)&v179.sFrame); } else { v136 = nullptr; } v137 = ((double (__fastcall *)(CCLightFlash *, cocos2d::CCParticleSystemQuad *, __int64))v115->addChild_0)( v115, v136, 11); ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *))v136->setScale_0)(v136); cocos2d::CCParticleSystem::resetSystem(v136); v138 = v136->cocos2d::CCParticleSystem::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v115->getContentSize(v115); v139 = (float *)v115->getContentSize(v115); cocos2d::CCPoint::CCPoint(*(float *)&v137, *v139 * 0.5); v138->setPosition_0(v136, v140); v176 = 0; v177 = 0; v178 = 15; v141 = sub_14003AA10(0xC0u); *(_QWORD *)&v176 = v141; v177 = 183; v178 = 191; qmemcpy( v141, "20a-1a2a0.3a8a90a90a0a2a27a30a0a0a0a0a0a0a75a28a0a360a0a0a0.839216a0a1a0a0.05a0a0a0a0a0a0.184314a0a0a0a1a0a0.0" "5a0a0.73a0a0.71a0a0a0a0a0a0a0a0a2a1a1a0a0a184a0a0a0a0a0a0a1a0a0a0a0a0a0a", 182); v141[91] = *(unsigned __int8 *)(0x140000000LL + 5817478); if ( v177 ) { sub_140063B90((__int64)&v180); GameToolbox::particleStringToStruct((__int64 *)&v176, (__int64)&v180); v142 = GameToolbox::particleFromStruct(&v180, nullptr, 0); sub_14003A830((__int64)&v180.sFrame); } else { v142 = nullptr; } v143 = ((double (__fastcall *)(CCLightFlash *, cocos2d::CCParticleSystemQuad *, __int64))v115->addChild_0)( v115, v142, 11); ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *))v142->setScale_0)(v142); cocos2d::CCParticleSystem::resetSystem(v142); v144 = v142->cocos2d::CCParticleSystem::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v115->getContentSize(v115); v145 = (float *)v115->getContentSize(v115); cocos2d::CCPoint::CCPoint(*(float *)&v143, *v145 * 0.5); v144->setPosition_0(v142, v146); v173 = 0; v174 = 0; v175 = 15; *(_QWORD *)&v173 = sub_14003AA10(0xC0u); v174 = 178; v175 = 191; strcpy( (char *)v173, "3a-1a3a0.3a1a90a90a0a2a11a13a0a0a0a0a0a0a15a5a0a0a0a0a0.839216a0a1a0a0.15a0.16a0a0a0a0a0.184314a0a0a0a1a0a0.21" "a0.07a1a0a1a0a0a0a0a0a0a0a0a2a1a1a0a0a34a0a0a0a0a0a0a1a0a0a0a0a0a0a0"); if ( v174 ) { sub_140063B90((__int64)&v181); GameToolbox::particleStringToStruct((__int64 *)&v173, (__int64)&v181); v5 = GameToolbox::particleFromStruct(&v181, nullptr, 0); sub_14003A830((__int64)&v181.sFrame); } v147 = ((double (__fastcall *)(CCLightFlash *, cocos2d::CCParticleSystemQuad *, __int64))v115->addChild_0)( v115, v5, 11); ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *))v5->setScale_0)(v5); cocos2d::CCParticleSystem::resetSystem(v5); v148 = v5->cocos2d::CCParticleSystem::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v115->getContentSize(v115); v149 = (float *)v115->getContentSize(v115); cocos2d::CCPoint::CCPoint(*(float *)&v147, *v149 * 0.5); v148->setPosition_0(v5, v150); v151 = 20; do { ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *))v136->update)(v136); ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *))v142->update)(v142); --v151; } while ( v151 ); sub_14003A830((__int64)&v173); sub_14003A830((__int64)&v176); sub_14003A830((__int64)&v170[1]); goto LABEL_76; } ((void (__fastcall *)(CCMenuItemSpriteExtra *, __int64))v116->~CCMenuItemSpriteExtra)(v116, 1); } v116 = nullptr; goto LABEL_62; } for ( j = 0; j < cocos2d::CCArray::count(a1->m_progressObjects); ++j ) { v13 = cocos2d::CCArray::objectAtIndex(a1->m_progressObjects, j); LOBYTE(v14) = 1; ((void (__fastcall *)(struct cocos2d::CCObject *, __int64))v13->__vftable[4].update)(v13, v14); } for ( k = 0; k < cocos2d::CCArray::count(a1->m_levelObjects); ++k ) { v16 = cocos2d::CCArray::objectAtIndex(a1->m_levelObjects, k); LOBYTE(v17) = 1; ((void (__fastcall *)(struct cocos2d::CCObject *, __int64))v16->__vftable[4].update)(v16, v17); } v18 = (float)(a1->m_level->m_normalPercent.random - a1->m_level->m_normalPercent.seed) / 100.0; m_progressWidth = a1->m_progressWidth; if ( (float)(m_progressWidth * v18) <= m_progressWidth ) m_progressWidth = m_progressWidth * v18; m_normalProgressBar = a1->m_normalProgressBar; v21 = m_normalProgressBar->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCRect::CCRect(&v162, 0.0, 0.0, m_progressWidth, m_normalProgressBar->m_obRect.size.height); v21->setTextureRect_0(a1->m_normalProgressBar, v22); m_practiceProgressBar = a1->m_practiceProgressBar; v24 = m_practiceProgressBar->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCRect::CCRect( &v162, 0.0, 0.0, fminf(a1->m_progressWidth, (float)((float)a1->m_level->m_practicePercent / 100.0) * a1->m_progressWidth), m_practiceProgressBar->m_obRect.size.height); v24->setTextureRect_0(a1->m_practiceProgressBar, v25); v26 = cocos2d::CCString::createWithFormat( "%i%%", a1->m_level->m_normalPercent.random - a1->m_level->m_normalPercent.seed); CString = cocos2d::CCString::getCString(v26); a1->m_normalProgressLabel->setString(&a1->m_normalProgressLabel->cocos2d::CCLabelProtocol, CString); v28 = cocos2d::CCString::createWithFormat("%i%%", a1->m_level->m_practicePercent); v29 = cocos2d::CCString::getCString(v28); a1->m_practiceProgressLabel->setString(&a1->m_practiceProgressLabel->cocos2d::CCLabelProtocol, v29); v30 = (GameStatsManager *)qword_1406C2EE8; if ( !qword_1406C2EE8 ) { v168 = operator new(0x3E0u); qword_1406C2EE8 = sub_1401D0AE0((__int64)v168); (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2EE8 + 72LL))(qword_1406C2EE8); v30 = (GameStatsManager *)qword_1406C2EE8; } LODWORD(v170[0]) = GameStatsManager::getStat(v30, "8"); LODWORD(v168) = a1->m_level->m_requiredCoins; ((void (__fastcall *)(cocos2d::CCLabelBMFont *))a1->m_nameLabel->setScale_0)(a1->m_nameLabel); sub_14003BDB0((__int64)&v170[1], (__int64)&a1->m_level->m_levelName); v31 = (const char *)&v170[1]; if ( v172 > 0xF ) v31 = (const char *)v170[1]; a1->m_nameLabel->setString(&a1->m_nameLabel->cocos2d::CCLabelProtocol, v31); sub_14003A830((__int64)&v170[1]); if ( a1->m_nameLabel->getContentSize(a1->m_nameLabel)->width > 250.0 ) { m_nameLabel = a1->m_nameLabel; v33 = m_nameLabel->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; m_nameLabel->getContentSize(m_nameLabel); ((void (__fastcall *)(cocos2d::CCLabelBMFont *))v33->setScale_0)(a1->m_nameLabel); } a1->m_nameLabel->getScale(a1->m_nameLabel); ((void (__fastcall *)(cocos2d::CCLabelBMFont *))a1->m_nameLabel->setScale_0)(a1->m_nameLabel); m_difficulty = a1->m_level->m_difficulty; v35 = 1; if ( m_difficulty <= Easy ) { v36 = Easy; } else { v36 = Demon; if ( m_difficulty < Demon ) v36 = a1->m_level->m_difficulty; } v37 = cocos2d::CCString::createWithFormat("diffIcon_%02d_btn_001.png", v36); v38 = cocos2d::CCString::getCString(v37); m_difficultySprite = a1->m_difficultySprite; v40 = m_difficultySprite->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v41 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(m_difficultySprite); v42 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v41, v38); v40->setDisplayFrame(a1->m_difficultySprite, v42); v43 = a1->m_difficultySprite; v44 = ((double (__fastcall *)(cocos2d::CCSprite *))v43->getScale)(v43); v45 = *(float *)&v44 * v43->m_obRect.size.width; v46 = a1->m_nameLabel->getContentSize(a1->m_nameLabel); *(float *)&v44 = (float)(a1->m_nameLabel->getScale(a1->m_nameLabel) * v46->width) + 5.0; v47 = a1->m_difficultySprite->__vftable; v48 = cocos2d::CCPoint::CCPoint( *(float *)&v44, (float)((float)(a1->m_levelDisplaySize.width * 0.5) - (float)((float)((float)((float)(v45 * 0.5) + *(float *)&v44) + 30.0) * 0.5)) + (float)(v45 * 0.5)); v47->setPosition_0(a1->m_difficultySprite, v49); v50 = a1->m_nameLabel->__vftable; v51 = a1->m_difficultySprite->getPosition_0(a1->m_difficultySprite); cocos2d::CCPoint::CCPoint(*(float *)&v48, v51->x + 30.0); v50->setPosition_0(a1->m_nameLabel, v52); v53 = a1->m_starsLabel->__vftable; v54 = cocos2d::CCString::createWithFormat("%i", a1->m_level->m_stars.random - a1->m_level->m_stars.seed); v55 = cocos2d::CCString::getCString(v54); v53->setString(&a1->m_starsLabel->cocos2d::CCLabelProtocol, v55); v56 = (GameStatsManager *)qword_1406C2EE8; if ( !qword_1406C2EE8 ) { v162.origin = (cocos2d::CCPoint)operator new(0x3E0u); qword_1406C2EE8 = sub_1401D0AE0(*(_QWORD *)&v162.origin); (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2EE8 + 72LL))(qword_1406C2EE8); v56 = (GameStatsManager *)qword_1406C2EE8; } hasCompletedStarLevel = GameStatsManager::hasCompletedStarLevel(v56, a1->m_level); v58 = &a1->m_starsLabel->cocos2d::CCRGBAProtocol; if ( hasCompletedStarLevel ) { v160 = -1; v161 = 50; v59 = &v160; } else { v59 = &word_140529B6C; } v58->setColor(v58, (const cocos2d::ccColor3B *)v59); do { v60 = (GameStatsManager *)qword_1406C2EE8; if ( !qword_1406C2EE8 ) { v162.origin = (cocos2d::CCPoint)operator new(0x3E0u); qword_1406C2EE8 = sub_1401D0AE0(*(_QWORD *)&v162.origin); (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2EE8 + 72LL))(qword_1406C2EE8); v60 = (GameStatsManager *)qword_1406C2EE8; } v61 = a1->m_level; v62 = (unsigned int)(v61->m_levelID.random - v61->m_levelID.seed); if ( v61->m_dailyID.random - v61->m_dailyID.seed <= 0 ) { v64 = "%i_%i_g"; if ( !v61->m_gauntletLevel ) v64 = "%i_%i"; v63 = cocos2d::CCString::createWithFormat(v64, v62, (unsigned int)v35); } else { v63 = cocos2d::CCString::createWithFormat("%i_%i_%i", v62, v35, v61->m_dailyID.random - v61->m_dailyID.seed); } v65 = cocos2d::CCString::getCString(v63); hasSecretCoin = GameStatsManager::hasSecretCoin(v60, v65); v68 = cocos2d::CCArray::objectAtIndex(a1->m_coins, v35 - 1); v69 = v68->__vftable; v70 = "GJ_coinsIcon_001.png"; if ( !hasSecretCoin ) v70 = "GJ_coinsIcon_gray_001.png"; v71 = (cocos2d::CCSpriteFrameCache *)cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v67); v72 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v71, v70); ((void (__fastcall *)(struct cocos2d::CCObject *, struct cocos2d::CCSpriteFrame *))v69[13].getTag)(v68, v72); if ( hasSecretCoin ) { v163 = -1; v164 = -1; v73 = &v163; } else { v165 = -7711; v166 = -7711; v167 = -31; v73 = &v166; } (**(void (__fastcall ***)(__int64, __int16 *))&v68[5].m_unknown2)((__int64)&v68[5].m_unknown2, v73); ++v35; } while ( v35 <= 3 ); v74 = v170[0]; v75 = (int)v168; v76 = 0; if ( (int)v168 <= SLODWORD(v170[0]) ) { v94 = (GameStatsManager *)qword_1406C2EE8; if ( !qword_1406C2EE8 ) { v162.origin = (cocos2d::CCPoint)operator new(0x3E0u); qword_1406C2EE8 = sub_1401D0AE0(*(_QWORD *)&v162.origin); (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2EE8 + 72LL))(qword_1406C2EE8); v94 = (GameStatsManager *)qword_1406C2EE8; } BaseCurrencyForLevel = GameStatsManager::getBaseCurrencyForLevel(v94, a1->m_level); v96 = (GameStatsManager *)qword_1406C2EE8; if ( !qword_1406C2EE8 ) { v162.origin = (cocos2d::CCPoint)operator new(0x3E0u); qword_1406C2EE8 = sub_1401D0AE0(*(_QWORD *)&v162.origin); (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2EE8 + 72LL))(qword_1406C2EE8); v96 = (GameStatsManager *)qword_1406C2EE8; } AwardedCurrencyForLevel = GameStatsManager::getAwardedCurrencyForLevel(v96, a1->m_level); v82 = cocos2d::CCSprite::createWithSpriteFrameName((const char *)&xmmword_14053DCE8); a1->m_levelDisplay->addChild_1(a1->m_levelDisplay, v82); ((void (__fastcall *)(struct cocos2d::CCSprite *))v82->setScale_0)(v82); v98 = cocos2d::CCString::createWithFormat( "%i/%i", AwardedCurrencyForLevel, (int)(float)((float)BaseCurrencyForLevel * 0.25) + BaseCurrencyForLevel); v99 = cocos2d::CCString::getCString(v98); v88 = cocos2d::CCLabelBMFont::create(v99, (const char *)&qword_14052A4D8); v100 = ((float (__fastcall *)(cocos2d::extension::CCScale9Sprite *, struct cocos2d::CCLabelBMFont *))a1->m_levelDisplay->addChild_1)( a1->m_levelDisplay, v88); v101 = v88->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCPoint::CCPoint(v100, 0.0); v103 = ((float (__fastcall *)(struct cocos2d::CCLabelBMFont *, __int64))v101->setAnchorPoint)(v88, v102); v104 = v88->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCPoint::CCPoint(v103, 8.0); v104->setPosition_0(v88, v105); ((void (__fastcall *)(struct cocos2d::CCLabelBMFont *))v88->setScale_0)(v88); v106 = v82->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; v88->getPosition_0(v88); width = v88->getContentSize(v88)->width; v108 = ((double (__fastcall *)(struct cocos2d::CCLabelBMFont *))v88->getScale)(v88); v109 = (float)((float)(*(float *)&v108 * width) + v88->getPosition_0(v88)->x) + 9.0; cocos2d::CCPoint::CCPoint(*(float *)&v108, v109); v106->setPosition_0(v82, v110); } else { if ( cocos2d::CCArray::count(a1->m_levelObjects) ) { do { v77 = cocos2d::CCArray::objectAtIndex(a1->m_levelObjects, v76); ((void (__fastcall *)(struct cocos2d::CCObject *, _QWORD))v77->__vftable[4].update)(v77, 0); ++v76; } while ( v76 < cocos2d::CCArray::count(a1->m_levelObjects) ); } v78 = cocos2d::CCSprite::createWithSpriteFrameName("GJLargeLock_001.png"); v79 = ((float (__fastcall *)(cocos2d::extension::CCScale9Sprite *, struct cocos2d::CCSprite *))a1->m_levelDisplay->addChild_1)( a1->m_levelDisplay, v78); v80 = v78->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCPoint::CCPoint(v79, a1->m_levelDisplaySize.width * 0.5); v80->setPosition_0(v78, v81); v82 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_coinsIcon_001.png"); a1->m_levelDisplay->addChild_1(a1->m_levelDisplay, v82); v83 = ((float (__fastcall *)(struct cocos2d::CCSprite *))v82->setScale_0)(v82); v84 = v82->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCPoint::CCPoint(v83, a1->m_levelDisplaySize.width - 15.0); v84->setPosition_0(v82, v85); v86 = cocos2d::CCString::createWithFormat("%i/%i", v74, v75); v87 = cocos2d::CCString::getCString(v86); v88 = cocos2d::CCLabelBMFont::create(v87, (const char *)&qword_14052A4D8); v89 = ((float (__fastcall *)(cocos2d::extension::CCScale9Sprite *, struct cocos2d::CCLabelBMFont *))a1->m_levelDisplay->addChild_1)( a1->m_levelDisplay, v88); v90 = v88->cocos2d::CCSpriteBatchNode::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; cocos2d::CCPoint::CCPoint(v89, 1.0); v92 = ((float (__fastcall *)(struct cocos2d::CCLabelBMFont *, __int64))v90->setAnchorPoint)(v88, v91); cocos2d::CCPoint::CCPoint(v92, -15.0); v93 = (__int64)v82->getPosition_0(v82); cocos2d::CCPoint::operator+(v93, &v168); v88->setPosition_0(v88, (const cocos2d::CCPoint *)&v168); ((void (__fastcall *)(struct cocos2d::CCLabelBMFont *))v88->setScale_0)(v88); cocos2d::CCArray::addObject(a1->m_dynamicObjects, v78); } cocos2d::CCArray::addObject(a1->m_dynamicObjects, v82); cocos2d::CCArray::addObject(a1->m_dynamicObjects, v88); LABEL_76: m_coinObject = a1->m_coinObject; if ( m_coinObject ) { v158 = a1->m_level; LOBYTE(v158) = v158->m_levelID.random - v158->m_levelID.seed == -1; m_coinObject->setVisible(m_coinObject, (bool)v158); } a1->m_isBusy = 0; }
GD Web Decomp Icon

GD Web Decomp

Raw Source