// // ShardsPage::init from 0x95c458 to 0x95de30 (6616 bytes) // // 3 xrefs: // > ShardsPage::create @ 0x95df44 // > @ 0x3b940 // > @ 0x11bb530 // // 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 // bool ShardsPage::init(ShardsPage *a1) { cocos2d::CCDirector *v3; // x0 int v4; // w21 cocos2d::CCNode *v5; // x20 void (__fastcall *setContentSize)(cocos2d::CCNode *__hidden, const cocos2d::CCSize *); // x23 void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x23 cocos2d::CCSprite *v8; // x20 void (__fastcall *v9)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x23 void (__fastcall *v10)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x21 cocos2d::CCSprite *v11; // x21 void (__fastcall *v12)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x23 cocos2d::CCSprite *v13; // x21 void (__fastcall *v14)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x23 cocos2d::CCSprite *v15; // x21 void (__fastcall *v16)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x23 cocos2d::CCDictionary *v17; // x0 cocos2d::CCSprite *v18; // x0 CCMenuItemSpriteExtra *v19; // x20 cocos2d::CCMenu *v20; // x20 float v21; // s1 void (__fastcall *v22)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x21 signed int v23; // w20 double v24; // d0 GameStatsManager *v25; // x0 _BOOL4 v26; // w0 cocos2d::CCSprite *v27; // x20 void (__fastcall *v28)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x21 cocos2d::CCString *v29; // x0 cocos2d::CCLabelBMFont *v30; // x24 void (__fastcall *setAnchorPoint)(cocos2d::CCLabelBMFont *__hidden, const cocos2d::CCPoint *); // x21 void (__fastcall *v32)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x21 __int64 v33; // x23 float *v34; // x0 cocos2d::CCSprite *v35; // x20 void (__fastcall *v36)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x21 void (__fastcall *v37)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x21 __int64 v38; // x23 __int64 v39; // x24 unsigned int v40; // w21 cocos2d::CCString *v41; // x0 char *CString; // x0 GameManager *v43; // x20 void *v44; // x0 GJItemIcon *v45; // x25 CCMenuItemSpriteExtra *v46; // x20 void (__fastcall *v47)(cocos2d::CCNode *__hidden, const cocos2d::CCSize *); // x27 __int64 v48; // x0 void (__fastcall *v49)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x27 float width; // s8 __int64 v51; // x0 void (__fastcall *v52)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 cocos2d::CCSprite *v53; // x20 void (__fastcall *v54)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x26 void (__fastcall *setScaleX)(cocos2d::CCSprite *__hidden, float); // x26 float *v56; // x0 void (__fastcall *setScaleY)(cocos2d::CCSprite *__hidden, float); // x26 __int64 v58; // x0 int v59; // w20 float v60; // s8 cocos2d::CCSprite *v61; // x25 void (__fastcall *v62)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x20 void (__fastcall *v63)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x20 void (__fastcall *v64)(cocos2d::CCSprite *__hidden, float); // x20 float *v65; // x0 void (__fastcall *v66)(cocos2d::CCSprite *__hidden, float); // x20 __int64 v67; // x0 __int64 v68; // x1 void *v69; // x0 char *v70; // x0 char *v71; // x0 char *v72; // x0 cocos2d::CCMenu *v73; // x20 float v74; // s8 cocos2d::CCSprite *v75; // x0 CCMenuItemSpriteExtra *v76; // x0 cocos2d::CCMenu_vtbl *v77; // x2 CCMenuItemSpriteExtra *m_prevButton; // x24 void (__fastcall *v79)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x25 cocos2d::CCDirector *v80; // x0 float v81; // s0 cocos2d::CCSprite *v82; // x21 CCMenuItemSpriteExtra *v83; // x0 cocos2d::CCMenu_vtbl *v84; // x2 CCMenuItemSpriteExtra *m_nextButton; // x21 void (__fastcall *v86)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x23 cocos2d::CCDirector *v87; // x0 float v88; // s0 cocos2d::CCSprite *v89; // x0 cocos2d::CCSprite *m_tierSprite; // x20 void (__fastcall *v91)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x21 cocos2d::CCString *v92; // x0 cocos2d::CCLabelBMFont *v93; // x20 void (__fastcall *v94)(cocos2d::CCLabelBMFont *__hidden, const cocos2d::CCPoint *); // x26 void (__fastcall *v95)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x26 float v96; // s0 cocos2d::CCSprite *v97; // x26 void (__fastcall *v98)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x27 void (__fastcall *v99)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x27 unsigned int *v100; // x1 int v101; // w2 double v102; // d0 GameStatsManager *v103; // x0 int v104; // w21 _BOOL4 v105; // w0 double v106; // d0 GameStatsManager *v107; // x0 double v108; // d0 GameStatsManager *v109; // x0 double v110; // d0 GameStatsManager *v111; // x0 double v112; // d0 double v113; // d0 double v114; // d0 GameStatsManager *v115; // x0 int Stat; // w21 double v117; // d0 GameStatsManager *v118; // x0 double v119; // d0 GameStatsManager *v120; // x0 double v121; // d0 GameStatsManager *v122; // x0 double v123; // d0 GameStatsManager *v124; // x0 unsigned int *v125; // x1 int v126; // w2 unsigned int *v127; // x1 int v128; // w2 unsigned int *v129; // x1 int v130; // w2 unsigned int *v131; // x1 int v132; // w2 double v133; // d0 double v134; // d0 float v135; // s0 void (__fastcall *v136)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x23 char v137; // [xsp+ABh] [xbp+ABh] int v138; // [xsp+ACh] [xbp+ACh] cocos2d::CCSprite *v139; // [xsp+C0h] [xbp+C0h] cocos2d::CCMenu *m_buttonMenu; // [xsp+F8h] [xbp+F8h] cocos2d::CCNode *v141; // [xsp+F8h] [xbp+F8h] int v142; // [xsp+100h] [xbp+100h] int v143; // [xsp+104h] [xbp+104h] cocos2d::CCArray *v144; // [xsp+110h] [xbp+110h] int v145; // [xsp+118h] [xbp+118h] int v146; // [xsp+11Ch] [xbp+11Ch] char *v147; // [xsp+120h] [xbp+120h] __int64 v148; // [xsp+128h] [xbp+128h] char v149; // [xsp+130h] [xbp+130h] BYREF char v150; // [xsp+131h] [xbp+131h] char v151; // [xsp+132h] [xbp+132h] char v152; // [xsp+138h] [xbp+138h] BYREF char v153; // [xsp+139h] [xbp+139h] char v154; // [xsp+13Ah] [xbp+13Ah] __int64 v155; // [xsp+140h] [xbp+140h] UnlockType v156; // [xsp+148h] [xbp+148h] BYREF int v157; // [xsp+14Ch] [xbp+14Ch] BYREF float v158; // [xsp+150h] [xbp+150h] float v159; // [xsp+154h] [xbp+154h] cocos2d::CCPoint v160; // [xsp+158h] [xbp+158h] BYREF cocos2d::CCPoint v161; // [xsp+160h] [xbp+160h] BYREF const char *v162; // [xsp+168h] [xbp+168h] BYREF const char *v163; // [xsp+170h] [xbp+170h] BYREF const char *v164; // [xsp+178h] [xbp+178h] BYREF __int64 v165; // [xsp+180h] [xbp+180h] BYREF __int64 v166; // [xsp+188h] [xbp+188h] BYREF cocos2d::CCPoint v167; // [xsp+190h] [xbp+190h] BYREF __int64 v168; // [xsp+198h] [xbp+198h] BYREF cocos2d::CCPoint v169; // [xsp+1A0h] [xbp+1A0h] BYREF cocos2d::CCRect v170; // [xsp+1A8h] [xbp+1A8h] BYREF cocos2d::CCPoint v171; // 0:kr10_8.8 cocos2d::CCPoint v172; // 0:kr18_8.8 cocos2d::CCPoint v173; // 0:kr20_8.8 cocos2d::SEL_MenuHandler v174; // 0:x2.16 cocos2d::SEL_MenuHandler v175; // 0:x2.16 cocos2d::SEL_MenuHandler v176; // 0:x2.16 cocos2d::SEL_MenuHandler v177; // 0:x2.16 cocos2d::CCRect v178; // 0:s0.4,4:s1.4,8:s2.4,12:s3.4 v137 = FLAlertLayer::init(a1, 0x96u); if ( v137 ) { v3 = cocos2d::CCDirector::sharedDirector(); cocos2d::CCDirector::getWinSize(v3); v4 = 1; cocos2d::CCRect::CCRect(&v170, 0.0, 0.0, 80.0, 80.0); v5 = (cocos2d::CCNode *)cocos2d::extension::CCScale9Sprite::create( (cocos2d::extension::CCScale9Sprite *)"GJ_square01.png", (const char *)&v170, v178); ((void (__fastcall *)(cocos2d::CCNode *, __int64))v5->__vftable[1].~CCNode_0)(v5, 0xFFFFFFFFLL); setContentSize = v5->setContentSize; cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v170, 420.0, 280.0); setContentSize(v5, (const cocos2d::CCSize *)&v170); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v5, -1); setPosition = v5->setPosition; cocos2d::CCPoint::CCPoint(&v170.origin, v158 * 0.5, v159 * 0.5); setPosition(v5, &v170.origin); while ( 1 ) { while ( 1 ) { v8 = cocos2d::CCSprite::createWithSpriteFrameName("dailyLevelCorner_001.png"); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v8, 8); if ( v4 != 3 ) break; cocos2d::CCSprite::setFlipX(v8, 1); cocos2d::CCSprite::setFlipY(v8, 1); v135 = 185.0; LABEL_86: ++v4; v136 = v8->setPosition; cocos2d::CCPoint::CCPoint(&v170.origin, v135 + (float)(v158 * 0.5), (float)(v159 * 0.5) + 115.0); v136(v8, &v170.origin); } if ( v4 == 4 ) break; if ( v4 == 2 ) { cocos2d::CCSprite::setFlipY(v8, 1); v135 = -185.0; goto LABEL_86; } v9 = v8->setPosition; cocos2d::CCPoint::CCPoint(&v170.origin, (float)(v158 * 0.5) + -185.0, (float)(v159 * 0.5) + -115.0); v9(v8, &v170.origin); ++v4; } cocos2d::CCSprite::setFlipX(v8, 1); v10 = v8->setPosition; cocos2d::CCPoint::CCPoint(&v170.origin, (float)(v158 * 0.5) + 185.0, (float)(v159 * 0.5) + -115.0); v10(v8, &v170.origin); v138 = -1; v142 = -1; v145 = 0; cocos2d::CCPoint::CCPoint(&v160, v158 * 0.5, (float)((float)(v159 * 0.5) + 140.0) - 28.0); v11 = cocos2d::CCSprite::createWithSpriteFrameName("label_shards_001.png"); v12 = v11->setPosition; cocos2d::CCPoint::CCPoint(&v169, -80.0, 0.0); cocos2d::CCPoint::operator+(&v170, &v160, &v169); v12(v11, &v170.origin); a1->m_mainLayer->addChild(a1->m_mainLayer, v11); v13 = cocos2d::CCSprite::createWithSpriteFrameName("label_of_001.png"); v14 = v13->setPosition; cocos2d::CCPoint::CCPoint(&v169, 4.0, 0.0); cocos2d::CCPoint::operator+(&v170, &v160, &v169); v14(v13, &v170.origin); a1->m_mainLayer->addChild(a1->m_mainLayer, v13); v15 = cocos2d::CCSprite::createWithSpriteFrameName("label_power_001.png"); v16 = v15->setPosition; cocos2d::CCPoint::CCPoint(&v169, 85.0, 0.0); cocos2d::CCPoint::operator+(&v170, &v160, &v169); v16(v15, &v170.origin); a1->m_mainLayer->addChild(a1->m_mainLayer, v15); cocos2d::CCPoint::CCPoint(&v161, v158 * 0.5, (float)(v159 * 0.5) + 80.0); v17 = cocos2d::CCDictionary::create(); a1->m_pages = v17; cocos2d::CCObject::retain(v17); v18 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_closeBtn_001.png"); v174.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v174.adj = (size_t)ShardsPage::onClose; v19 = CCMenuItemSpriteExtra::create(v18, nullptr, v174); CCMenuItemSpriteExtra::setSizeMult(v19, 1.6); v20 = (cocos2d::CCMenu *)cocos2d::CCMenu::create((cocos2d::CCMenu *)v19, nullptr); v21 = v158; a1->m_buttonMenu = v20; v22 = v20->setPosition; cocos2d::CCPoint::CCPoint( &v170.origin, (float)((float)(v21 * 0.5) + -210.0) + 10.0, (float)((float)(v159 * 0.5) + 140.0) - 10.0); v22(v20, &v170.origin); a1->m_mainLayer->addChild_0(a1->m_mainLayer, a1->m_buttonMenu, 10); v139 = cocos2d::CCSprite::createWithSpriteFrameName("playerSquare_001.png"); LABEL_9: v23 = vcvtms_s32_f32((float)(v145 / 3)); v144 = (cocos2d::CCArray *)cocos2d::CCDictionary::objectForKey(a1->m_pages, v23); if ( !v144 ) { v144 = (cocos2d::CCArray *)cocos2d::CCArray::create(nullptr); cocos2d::CCDictionary::setObject(a1->m_pages, v144, v23); } v162 = &byte_124B6C8; LOBYTE(v147) = -1; v163 = &byte_124B6C8; BYTE2(v147) = -1; LOWORD(v148) = -1; BYTE2(v148) = -1; v149 = -1; v150 = -1; v151 = -1; v152 = -1; v153 = -1; v154 = -1; sub_D153B8((int)&v164, &byte_F288A0); switch ( v145 ) { case 1: *(_QWORD *)&v121 = sub_D1798C(&v162, "iceShardLabel_001.png", 21).n128_u64[0]; sub_D1798C(&v163, "iceShardSmall_001.png", 21, v121); v122 = GameStatsManager::sharedState(); Stat = GameStatsManager::getStat(v122, "19"); v143 = Stat; LOWORD(v147) = -27136; LOBYTE(v148) = 0; v149 = 100; v150 = -1; v151 = -1; v152 = 0; v153 = -1; v154 = -1; sub_D1798C(&v164, "shardIce", 8); goto LABEL_56; case 2: *(_QWORD *)&v119 = sub_D1798C(&v162, "poisonShardLabel_001.png", 24).n128_u64[0]; sub_D1798C(&v163, "poisonShardSmall_001.png", 24, v119); v120 = GameStatsManager::sharedState(); Stat = GameStatsManager::getStat(v120, "17"); v143 = Stat; LOWORD(v147) = -24576; BYTE2(v147) = 0; LOBYTE(v148) = 0; BYTE2(v148) = 0; v149 = 75; v150 = -1; v151 = 75; v152 = 0; v153 = -1; v154 = 0; sub_D1798C(&v164, "shardPoison", 11); goto LABEL_56; case 3: *(_QWORD *)&v117 = sub_D1798C(&v162, "shadowShardLabel_001.png", 24).n128_u64[0]; sub_D1798C(&v163, "shadowShardSmall_001.png", 24, v117); v118 = GameStatsManager::sharedState(); LOBYTE(v147) = -106; Stat = GameStatsManager::getStat(v118, "16"); v143 = Stat; BYTE1(v148) = 50; *(_WORD *)((char *)&v147 + 1) = -14336; v149 = -1; v150 = 100; v151 = -1; v152 = -1; v153 = 0; v154 = -1; sub_D1798C(&v164, "shardShadow", 11); goto LABEL_56; case 4: *(_QWORD *)&v114 = sub_D1798C(&v162, "lavaShardLabel_001.png", 22).n128_u64[0]; sub_D1798C(&v163, "lavaShardSmall_001.png", 22, v114); v115 = GameStatsManager::sharedState(); Stat = GameStatsManager::getStat(v115, "20"); v143 = Stat; LOWORD(v147) = 175; BYTE2(v147) = 0; BYTE1(v148) = 50; BYTE2(v148) = 25; v149 = -1; v150 = 50; v151 = 50; v152 = -1; v153 = 0; v154 = 0; sub_D1798C(&v164, "shardLava", 9); LABEL_56: v26 = Stat < v142; goto LABEL_13; case 5: *(_QWORD *)&v112 = sub_D1798C(&v162, "bonusShardLabel_001.png", 23).n128_u64[0]; *(_QWORD *)&v113 = sub_D1798C(&v163, "bonusShardSmall_001.png", 23, v112).n128_u64[0]; LOWORD(v147) = -26986; BYTE2(v147) = -106; sub_D1798C(&v164, "shardBonus", 10, v113); v143 = v142; if ( v142 == -1 ) goto LABEL_54; break; case 6: *(_QWORD *)&v110 = sub_D1798C(&v162, "shard0201ShardLabel_001.png", 27).n128_u64[0]; sub_D1798C(&v163, "shard0201ShardSmall_001.png", 27, v110); v111 = GameStatsManager::sharedState(); LOWORD(v147) = 25251; BYTE2(v147) = 70; v143 = GameStatsManager::getStat(v111, "23"); LOWORD(v148) = -7939; BYTE2(v148) = -96; sub_D1798C(&v164, "shardEarth", 10); v105 = v143 < v138; goto LABEL_47; case 7: *(_QWORD *)&v108 = sub_D1798C(&v162, "shard0202ShardLabel_001.png", 27).n128_u64[0]; sub_D1798C(&v163, "shard0202ShardSmall_001.png", 27, v108); v109 = GameStatsManager::sharedState(); v104 = GameStatsManager::getStat(v109, "24"); v143 = v104; LOWORD(v147) = 150; BYTE2(v147) = 0; BYTE1(v148) = 0; BYTE2(v148) = 0; sub_D1798C(&v164, "shardBlood", 10); goto LABEL_46; case 8: *(_QWORD *)&v106 = sub_D1798C(&v162, "shard0203ShardLabel_001.png", 27).n128_u64[0]; sub_D1798C(&v163, "shard0203ShardSmall_001.png", 27, v106); v107 = GameStatsManager::sharedState(); v104 = GameStatsManager::getStat(v107, "25"); v143 = v104; LOWORD(v147) = -32640; BYTE2(v147) = 0x80; sub_D1798C(&v164, "shardMetal", 10); goto LABEL_46; case 9: *(_QWORD *)&v102 = sub_D1798C(&v162, "shard0204ShardLabel_001.png", 27).n128_u64[0]; sub_D1798C(&v163, "shard0204ShardSmall_001.png", 27, v102); v103 = GameStatsManager::sharedState(); v104 = GameStatsManager::getStat(v103, "26"); v143 = v104; *(_WORD *)((char *)&v147 + 1) = 32762; BYTE2(v148) = -64; sub_D1798C(&v164, "shardLight", 10); goto LABEL_46; case 10: *(_QWORD *)&v123 = sub_D1798C(&v162, "shard0205ShardLabel_001.png", 27).n128_u64[0]; sub_D1798C(&v163, "shard0205ShardSmall_001.png", 27, v123); v124 = GameStatsManager::sharedState(); v104 = GameStatsManager::getStat(v124, "27"); v143 = v104; LOBYTE(v147) = 100; *(_WORD *)((char *)&v147 + 1) = -27136; BYTE1(v148) = 0; BYTE2(v148) = 125; sub_D1798C(&v164, "shardSoul", 9); LABEL_46: v105 = v104 < v138; LABEL_47: if ( !v105 ) goto LABEL_48; goto LABEL_49; case 11: *(_QWORD *)&v133 = sub_D1798C(&v162, "bonusShardLabel_001.png", 23).n128_u64[0]; *(_QWORD *)&v134 = sub_D1798C(&v163, "bonusShard2Small_001.png", 24, v133).n128_u64[0]; LOWORD(v147) = -26986; BYTE2(v147) = -106; sub_D1798C(&v164, "shardBonusB", 11, v134); v143 = v138; LABEL_48: if ( v138 == -1 ) LABEL_49: v138 = v143; break; default: *(_QWORD *)&v24 = sub_D1798C(&v162, "fireShardLabel_001.png", 22).n128_u64[0]; sub_D1798C(&v163, "fireShardSmall_001.png", 22, v24); v25 = GameStatsManager::sharedState(); v143 = GameStatsManager::getStat(v25, "18"); *(_WORD *)((char *)&v147 + 1) = 75; BYTE1(v148) = -56; BYTE2(v148) = 0; v149 = -1; v150 = -1; v151 = 0; v152 = -1; v153 = -1; v154 = 0; sub_D1798C(&v164, "shardFire", 9); v26 = v143 < v142; LABEL_13: if ( v26 || v142 == -1 ) LABEL_54: v142 = v143; break; } cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, (float)(-3 * v23 + v145) * -77.0); cocos2d::CCPoint::operator+(&v165, &v161, &v170); v27 = cocos2d::CCSprite::createWithSpriteFrameName(v162); a1->m_mainLayer->addChild(a1->m_mainLayer, v27); v28 = v27->setPosition; cocos2d::CCPoint::CCPoint(&v169, -20.0, 0.0); cocos2d::CCPoint::operator+(&v170, &v165, &v169); v28(v27, &v170.origin); cocos2d::CCArray::addObject(v144, v27); v29 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%i", (const char *)(unsigned int)v143); cocos2d::CCString::getCString(v29); v30 = cocos2d::CCLabelBMFont::create(); v30->setScale(v30, 0.45); a1->m_mainLayer->addChild(a1->m_mainLayer, v30); setAnchorPoint = v30->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, 0.5); setAnchorPoint(v30, &v170.origin); v32 = v30->setPosition; v33 = (__int64)v27->getPosition(v27); v34 = (float *)v27->getContentSize(v27); cocos2d::CCPoint::CCPoint(&v169, (float)(*v34 * 0.5) + 5.0, 1.0); cocos2d::CCPoint::operator+(&v170, v33, &v169); v32(v30, &v170.origin); cocos2d::CCArray::addObject(v144, v30); v35 = cocos2d::CCSprite::createWithSpriteFrameName(v163); a1->m_mainLayer->addChild(a1->m_mainLayer, v35); v36 = v35->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, 0.5); v36(v35, &v170.origin); v37 = v35->setPosition; v38 = (__int64)v30->getPosition(v30); ((void (__fastcall *)(__int64 *__return_ptr, cocos2d::CCLabelBMFont *))v30->getScaledContentSize)(&v168, v30); cocos2d::CCPoint::CCPoint(&v169, *(float *)&v168 + 2.0, 0.0); cocos2d::CCPoint::operator+(&v170, v38, &v169); v37(v35, &v170.origin); cocos2d::CCArray::addObject(v144, v35); v39 = 0; v40 = 1; while ( 1 ) { v146 = *(_DWORD *)((char *)&unk_EFA290 + v39); v41 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"geometry.ach.%s%02d", v164, v40); CString = (char *)cocos2d::CCString::getCString(v41); sub_D153B8((int)&v166, CString); v156 = 0; v157 = 0; v43 = GameManager::sharedState(); sub_D18D28(&v170); GameManager::getUnlockForAchievement((__int64)v43, (__int64)&v170, &v157, &v156); v44 = (void *)(*(_QWORD *)&v170.origin - 24LL); if ( (__int64 *)(*(_QWORD *)&v170.origin - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v125 = (unsigned int *)(*(_QWORD *)&v170.origin - 8LL); do v126 = __ldaxr(v125); while ( __stlxr(v126 - 1, v125) ); } else { v126 = *(_DWORD *)(*(_QWORD *)&v170.origin - 8LL); *(_DWORD *)(*(_QWORD *)&v170.origin - 8LL) = v126 - 1; } if ( v126 <= 0 ) operator delete(v44); } if ( v156 <= 0 ) goto LABEL_27; v45 = GJItemIcon::create( v156, v157, (cocos2d::ccColor3B)v147, (cocos2d::ccColor3B)v148, 0, 0, 0, (cocos2d::ccColor3B)&unk_FFFFFF); v45->setScale(v45, 0.8); if ( v143 < v146 ) { GJItemIcon::changeToLockedState(v45, 1.25); LOBYTE(v155) = 87; *(_WORD *)((char *)&v155 + 1) = 7472; GJItemIcon::darkenStoreItem((__int64)v45, v155); } v175.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v175.adj = (size_t)ShardsPage::onIconInfo; v46 = CCMenuItemSpriteExtra::create(v45, nullptr, v175); a1->m_buttonMenu->addChild(a1->m_buttonMenu, v46); v47 = v46->setContentSize; v48 = (__int64)v139->getContentSize(v139); v47(v46, (const cocos2d::CCSize *)v48); v49 = v45->setPosition; width = v46->getContentSize(v46)->width; v51 = (__int64)v46->getContentSize(v46); cocos2d::CCPoint::CCPoint(&v170.origin, width * 0.5, *(float *)(v51 + 4) * 0.5); v49(v45, &v170.origin); v46->setTag(v46, v145); cocos2d::CCPoint::CCPoint(&v170.origin, (float)(int)(v40 - 3) * 70.0, -30.0); cocos2d::CCPoint::operator+(&v167, &v165, &v170); m_buttonMenu = a1->m_buttonMenu; v52 = v46->setPosition; cocos2d::CCNode::convertToWorldSpace(a1->m_mainLayer, &v167); v171 = cocos2d::CCNode::convertToNodeSpace(m_buttonMenu, &v169); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCRect *, float, float))v52)(v46, &v170, v171.x, v171.y); cocos2d::CCArray::addObject(v144, v46); if ( v143 < v146 ) { v92 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%i", (const char *)(unsigned int)v146); cocos2d::CCString::getCString(v92); v93 = cocos2d::CCLabelBMFont::create(); v93->setScale(v93, 0.3); a1->m_mainLayer->addChild(a1->m_mainLayer, v93); v94 = v93->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, 0.5); v94(v93, &v170.origin); v95 = v93->setPosition; if ( v146 > 9 ) v96 = -10.0; else v96 = -8.0; cocos2d::CCPoint::CCPoint(&v169, v96, -22.0); cocos2d::CCPoint::operator+(&v170, &v167, &v169); v95(v93, &v170.origin); v93->setColor(v93, (const cocos2d::ccColor3B *)&v149); cocos2d::CCArray::addObject(v144, v93); v97 = cocos2d::CCSprite::createWithSpriteFrameName(v163); a1->m_mainLayer->addChild(a1->m_mainLayer, v97); v97->setScale(v97, 0.7); v98 = v97->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, 0.5); v98(v97, &v170.origin); v99 = v97->setPosition; v141 = (cocos2d::CCNode *)v93->getPosition(v93); v93->getScaledContentSize(v93); cocos2d::CCPoint::CCPoint(&v169, *(float *)&v168 + 2.0, 0.0); cocos2d::CCPoint::operator+(&v170, v141, &v169); v99(v97, &v170.origin); cocos2d::CCArray::addObject(v144, v97); } if ( v40 == 1 ) goto LABEL_27; cocos2d::CCPoint::CCPoint(&v170.origin, -51.0, 0.0); cocos2d::CCPoint::operator+(&v168, &v167, &v170); v53 = cocos2d::CCSprite::createWithSpriteFrameName("whiteSquare20_001.png"); v54 = v53->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, 0.5); v54(v53, &v170.origin); v53->setPosition(v53, (const cocos2d::CCPoint *)&v168); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v53, 0); setScaleX = v53->setScaleX; v56 = (float *)v53->getContentSize(v53); setScaleX(v53, 32.0 / *v56); setScaleY = v53->setScaleY; v58 = (__int64)v53->getContentSize(v53); setScaleY(v53, 5.0 / *(float *)(v58 + 4)); v53->setColor(v53, (const cocos2d::ccColor3B *)algn_EFA2B0); v53->setOpacity(v53, 110); cocos2d::CCArray::addObject(v144, v53); v59 = 0; if ( v40 - 2 <= 3 ) v59 = *((_DWORD *)&unk_EFA290 + v40 + 10); v60 = (float)(v143 - v59) / (float)(v146 - v59); if ( v60 >= 1.0 ) break; if ( v60 > 0.0 ) goto LABEL_26; v68 = v166; v69 = (void *)(v166 - 24); if ( (__int64 *)(v166 - 24) != &qword_124B6B0 ) { LABEL_39: if ( &pthread_create ) { v100 = (unsigned int *)(v68 - 8); do v101 = __ldaxr(v100); while ( __stlxr(v101 - 1, v100) ); } else { v101 = *(_DWORD *)(v68 - 8); *(_DWORD *)(v68 - 8) = v101 - 1; } if ( v101 <= 0 ) operator delete(v69); } LABEL_28: ++v40; v39 += 4; if ( v40 == 6 ) { v70 = (char *)(v164 - 24); if ( v164 - 24 != (const char *)&qword_124B6B0 ) { if ( &pthread_create ) { v127 = (unsigned int *)(v164 - 8); do v128 = __ldaxr(v127); while ( __stlxr(v128 - 1, v127) ); } else { v128 = *((_DWORD *)v164 - 2); *((_DWORD *)v164 - 2) = v128 - 1; } if ( v128 <= 0 ) operator delete(v70); } v71 = (char *)(v163 - 24); if ( v163 - 24 != (const char *)&qword_124B6B0 ) { if ( &pthread_create ) { v131 = (unsigned int *)(v163 - 8); do v132 = __ldaxr(v131); while ( __stlxr(v132 - 1, v131) ); } else { v132 = *((_DWORD *)v163 - 2); *((_DWORD *)v163 - 2) = v132 - 1; } if ( v132 <= 0 ) operator delete(v71); } v72 = (char *)(v162 - 24); if ( v162 - 24 != (const char *)&qword_124B6B0 ) { if ( &pthread_create ) { v129 = (unsigned int *)(v162 - 8); do v130 = __ldaxr(v129); while ( __stlxr(v130 - 1, v129) ); } else { v130 = *((_DWORD *)v162 - 2); *((_DWORD *)v162 - 2) = v130 - 1; } if ( v130 <= 0 ) operator delete(v72); } if ( ++v145 == 12 ) { v73 = cocos2d::CCMenu::create(); v74 = v159 * 0.5; v75 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_arrow_01_001.png"); v176.adj = (size_t)ShardsPage::onSwitchPage; v176.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v76 = CCMenuItemSpriteExtra::create(v75, nullptr, v176); v77 = v73->cocos2d::CCLayerRGBA::cocos2d::CCLayer::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; a1->m_prevButton = v76; v77->addChild(v73, v76); m_prevButton = a1->m_prevButton; v79 = m_prevButton->setPosition; v80 = cocos2d::CCDirector::sharedDirector(); cocos2d::CCDirector::getScreenLeft(v80); cocos2d::CCPoint::CCPoint(&v169, v81 + 24.0, v74); v172 = cocos2d::CCNode::convertToNodeSpace(v73, &v169); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCRect *, float, float))v79)( m_prevButton, &v170, v172.x, v172.y); a1->m_prevButton->setTag(a1->m_prevButton, 0); CCMenuItemSpriteExtra::setSizeMult(a1->m_prevButton, 1.4); v82 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_arrow_01_001.png"); cocos2d::CCSprite::setFlipX(v82, 1); v177.adj = (size_t)ShardsPage::onSwitchPage; v177.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v83 = CCMenuItemSpriteExtra::create(v82, nullptr, v177); v84 = v73->cocos2d::CCLayerRGBA::cocos2d::CCLayer::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; a1->m_nextButton = v83; v84->addChild(v73, v83); m_nextButton = a1->m_nextButton; v86 = m_nextButton->setPosition; v87 = cocos2d::CCDirector::sharedDirector(); cocos2d::CCDirector::getScreenRight(v87); cocos2d::CCPoint::CCPoint(&v169, v88 - 24.0, v74); v173 = cocos2d::CCNode::convertToNodeSpace(v73, &v169); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCRect *, float, float))v86)( m_nextButton, &v170, v173.x, v173.y); a1->m_nextButton->setTag(a1->m_nextButton, 1); CCMenuItemSpriteExtra::setSizeMult(a1->m_nextButton, 1.4); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v73, 10); v89 = cocos2d::CCSprite::createWithSpriteFrameName("tier1Icon_001.png"); a1->m_tierSprite = v89; a1->m_mainLayer->addChild_0(a1->m_mainLayer, v89, 10); m_tierSprite = a1->m_tierSprite; v91 = m_tierSprite->setPosition; cocos2d::CCPoint::CCPoint( &v170.origin, (float)((float)(v158 * 0.5) + 210.0) - 18.0, (float)((float)(v159 * 0.5) + 140.0) - 18.0); v91(m_tierSprite, &v170.origin); ShardsPage::goToPage(a1, 0); return v137; } goto LABEL_9; } } v60 = 1.0; LABEL_26: v61 = cocos2d::CCSprite::createWithSpriteFrameName("whiteSquare20_001.png"); v62 = v61->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v170.origin, 0.0, 0.5); v62(v61, &v170.origin); v63 = v61->setPosition; cocos2d::CCPoint::CCPoint(&v169, 2.0, 0.0); cocos2d::CCPoint::operator+(&v170, &v168, &v169); v63(v61, &v170.origin); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v61, 1); v64 = v61->setScaleX; v65 = (float *)v61->getContentSize(v61); v64(v61, (float)(v60 * 28.0) / *v65); v66 = v61->setScaleY; v67 = (__int64)v61->getContentSize(v61); v66(v61, 2.0 / *(float *)(v67 + 4)); v61->setColor(v61, (const cocos2d::ccColor3B *)&v152); cocos2d::CCArray::addObject(v144, v61); LABEL_27: v68 = v166; v69 = (void *)(v166 - 24); if ( (__int64 *)(v166 - 24) != &qword_124B6B0 ) goto LABEL_39; goto LABEL_28; } return v137; }
GD Web Decomp Icon

GD Web Decomp

Raw Source