// // ItemInfoPopup::init from 0x794b94 to 0x7961c0 (5676 bytes) // // 2 xrefs: // > ItemInfoPopup::create @ 0x7962dc // > @ 0x81bd0 // // 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 ItemInfoPopup::init(ItemInfoPopup *a1, int a2, UnlockType a3) { char v6; // w25 cocos2d::CCDirector *v8; // x0 cocos2d::CCNode *v9; // x21 void (__fastcall *setContentSize)(cocos2d::CCNode *__hidden, const cocos2d::CCSize *); // x27 cocos2d::CCNode *v11; // x21 void (__fastcall *v12)(cocos2d::CCNode *__hidden, const cocos2d::CCSize *); // x24 cocos2d::CCString *v13; // x0 char *CString; // x0 cocos2d::CCLabelBMFont *v15; // x21 void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x24 AchievementManager *v17; // x0 GJItemIcon *BrowserItem; // x27 void (__fastcall *v19)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x28 cocos2d::CCMenu *v20; // x0 cocos2d::CCLayer *m_mainLayer; // x3 const char *v22; // x1 __int64 v23; // x2 __int64 v24; // x3 bool v25; // w4 __int64 v26; // x5 const char *v27; // x6 cocos2d::CCNode *v28; // x0 CCMenuItemSpriteExtra *v29; // x0 cocos2d::CCMenu *m_buttonMenu; // x26 void (__fastcall *v31)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 GameStatsManager *v32; // x0 int ItemUnlockState; // w26 GameManager *v34; // x27 GameManager *v35; // x0 IconType v36; // w0 GameStatsManager *v37; // x0 cocos2d::CCPoint origin; // x1 void *v39; // x0 cocos2d::CCString *v40; // x0 size_t v41; // x0 cocos2d::CCLabelBMFont *v42; // x28 void (__fastcall *v43)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 GameStatsManager *v44; // x0 int v45; // w0 cocos2d::CCArray **p_m_pTargetArray; // x0 cocos2d::CCArray **v47; // x0 void *v48; // x0 void *v49; // x0 cocos2d::CCArray **v50; // x0 char *v51; // x0 unsigned int *v52; // x20 int v53; // w1 void *v54; // x0 cocos2d::CCString *v55; // x0 size_t v56; // x0 void *v57; // x0 unsigned int *v58; // x1 int v59; // w2 cocos2d::CCNode *v60; // x28 void *v61; // x0 void (__fastcall *v62)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 cocos2d::CCLabelBMFont *v63; // x27 __int64 v64; // x27 GameStatsManager *v65; // x0 cocos2d::CCSprite *v66; // x1 float *v67; // x0 unsigned int *v68; // x1 int v69; // w2 AchievementManager *v70; // x28 int v71; // w24 char *p_m_fBrVertexMod; // x0 cocos2d::CCSprite *v73; // x27 void (__fastcall *setAnchorPoint)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x24 void (__fastcall *v75)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x28 char *v76; // x0 unsigned int *v77; // x1 int v78; // w2 cocos2d::CCString *v79; // x0 size_t v80; // x0 cocos2d::CCString *v81; // x0 size_t v82; // x0 unsigned int *v83; // x1 int v84; // w2 unsigned int *v85; // x1 int v86; // w2 unsigned int *v87; // x1 int v88; // w2 unsigned int *v89; // x1 int v90; // w2 unsigned int *p_m_nExtraKerning; // x1 int m_nExtraKerning; // w2 cocos2d::CCString *v93; // x0 cocos2d::CCLabelBMFont *v94; // x23 CCMenuItemSpriteExtra *v95; // x22 void (__fastcall *v96)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x24 void (__fastcall *setColor)(cocos2d::CCLabelBMFont *__hidden, const cocos2d::ccColor3B *); // x3 unsigned int *v98; // x1 int v99; // w2 cocos2d::CCString *v100; // x0 size_t v101; // x0 int v102; // w0 cocos2d::CCString *v103; // x0 size_t v104; // x0 int v105; // w0 unsigned int *v106; // x1 int v107; // w2 unsigned int *p_m_fTextureTop; // x1 int m_fTextureTop_low; // w2 unsigned int *v110; // x1 int v111; // w2 const char *v112; // [xsp+70h] [xbp+70h] const char *v113; // [xsp+70h] [xbp+70h] const char *v114; // [xsp+70h] [xbp+70h] bool isIconUnlocked; // [xsp+80h] [xbp+80h] const char *v116; // [xsp+80h] [xbp+80h] _BOOL4 v117; // [xsp+8Ch] [xbp+8Ch] const char *v118; // [xsp+98h] [xbp+98h] const char *v119; // [xsp+98h] [xbp+98h] void (__fastcall *v120)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+98h] [xbp+98h] void (__fastcall *v121)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+98h] [xbp+98h] float v122; // [xsp+B0h] [xbp+B0h] float v123; // [xsp+B4h] [xbp+B4h] cocos2d::CCPoint v124; // [xsp+B8h] [xbp+B8h] BYREF __int64 v125; // [xsp+C0h] [xbp+C0h] BYREF char *v126; // [xsp+C8h] [xbp+C8h] BYREF cocos2d::CCLabelBMFont *v127; // [xsp+D0h] [xbp+D0h] BYREF __int64 v128; // [xsp+D8h] [xbp+D8h] BYREF __int64 v129; // [xsp+E0h] [xbp+E0h] BYREF cocos2d::CCLabelBMFont *v130; // [xsp+E8h] [xbp+E8h] BYREF cocos2d::CCLabelBMFont *v131; // [xsp+F0h] [xbp+F0h] BYREF cocos2d::CCSprite *v132; // [xsp+F8h] [xbp+F8h] BYREF cocos2d::CCPoint v133; // [xsp+100h] [xbp+100h] BYREF cocos2d::CCRect v134; // [xsp+108h] [xbp+108h] BYREF cocos2d::CCPoint v135; // 0:kr08_8.8 cocos2d::SEL_MenuHandler v136; // 0:x2.16 cocos2d::SEL_MenuHandler v137; // 0:x2.16 cocos2d::CCRect v138; // 0:s0.4,4:s1.4,8:s2.4,12:s3.4 cocos2d::CCRect v139; // 0:s0.4,4:s1.4,8:s2.4,12:s3.4 v6 = FLAlertLayer::init(a1, 0x96u); if ( !v6 ) return v6; a1->setKeypadEnabled(a1, 1); a1->setTouchEnabled(a1, 1); a1->m_itemID = a2; a1->m_unlockType = a3; v8 = cocos2d::CCDirector::sharedDirector(); cocos2d::CCDirector::getWinSize(v8); cocos2d::CCRect::CCRect(&v134, 0.0, 0.0, 80.0, 80.0); v9 = (cocos2d::CCNode *)cocos2d::extension::CCScale9Sprite::create( (cocos2d::extension::CCScale9Sprite *)"GJ_square01.png", (const char *)&v134, v138); setContentSize = v9->setContentSize; cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v134, 300.0, 230.0); setContentSize(v9, (const cocos2d::CCSize *)&v134); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v9, -2); cocos2d::CCPoint::CCPoint(&v124, v122 * 0.5, v123 * 0.5); v9->setPosition(v9, &v124); cocos2d::CCPoint::CCPoint(&v134.origin, 0.0, -22.0); cocos2d::CCPoint::operator+(&v125, &v124, &v134); cocos2d::CCRect::CCRect(&v134, 0.0, 0.0, 80.0, 80.0); v11 = (cocos2d::CCNode *)cocos2d::extension::CCScale9Sprite::create( (cocos2d::extension::CCScale9Sprite *)"GJ_square01.png", (const char *)&v134, v139); ((void (__fastcall *)(cocos2d::CCNode *, void *))v11->__vftable[1].getTag)(v11, &unk_ECEDE0); ((void (__fastcall *)(cocos2d::CCNode *, __int64))v11->__vftable[1].~CCNode_0)(v11, 60); v12 = v11->setContentSize; cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v134, 260.0, 90.0); v12(v11, (const cocos2d::CCSize *)&v134); a1->m_mainLayer->addChild_0(a1->m_mainLayer, v11, -1); v11->setPosition(v11, (const cocos2d::CCPoint *)&v125); ItemInfoPopup::nameForUnlockType(a2, a3, (__int64)&v126); v13 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%s %i", v126, (unsigned int)a2); CString = (char *)cocos2d::CCString::getCString(v13); sub_D153B8((int)&v127, CString); v15 = cocos2d::CCLabelBMFont::create(); setPosition = v15->setPosition; cocos2d::CCPoint::CCPoint(&v134.origin, v124.x, (float)(v124.y + 115.0) - 16.0); setPosition(v15, &v134.origin); a1->m_mainLayer->addChild(a1->m_mainLayer, v15); v15->setScale(v15, 0.8); v17 = AchievementManager::sharedState(); AchievementManager::achievementForUnlock((__int64)v17, a2, a3, (__int64)&v128); if ( *(_QWORD *)(v128 - 24) ) { v70 = AchievementManager::sharedState(); sub_D18D28(&v132); v71 = AchievementManager::limitForAchievement(v70, (const char **)&v132); p_m_fBrVertexMod = (char *)&v132[-1].m_fBrVertexMod; if ( (__int64 *)&v132[-1].m_fBrVertexMod != &qword_124B6B0 ) { if ( &pthread_create ) { p_m_fTextureTop = (unsigned int *)&v132[-1].m_fTextureTop; do m_fTextureTop_low = __ldaxr(p_m_fTextureTop); while ( __stlxr(m_fTextureTop_low - 1, p_m_fTextureTop) ); } else { m_fTextureTop_low = LODWORD(v132[-1].m_fTextureTop); LODWORD(v132[-1].m_fTextureTop) = m_fTextureTop_low - 1; } if ( m_fTextureTop_low <= 0 ) operator delete(p_m_fBrVertexMod); } if ( (unsigned int)(v71 - 2) <= 2 ) { sub_D153B8((int)&v132, "gj_subzeroLogo_001.png"); if ( v71 == 2 ) { sub_D1798C(&v132, "gj_worldLogo_001.png", 20); } else if ( v71 == 4 ) { sub_D1798C(&v132, "GJ_md_001.png", 13); } v73 = cocos2d::CCSprite::createWithSpriteFrameName((const char *)v132); a1->m_mainLayer->addChild(a1->m_mainLayer, v73); setAnchorPoint = v73->setAnchorPoint; cocos2d::CCPoint::CCPoint(&v134.origin, 0.0, 1.0); setAnchorPoint(v73, &v134.origin); v73->setScale(v73, 0.4); v75 = v73->setPosition; cocos2d::CCPoint::CCPoint(&v133, -140.0, 105.0); cocos2d::CCPoint::operator+(&v134, &v124, &v133); v75(v73, &v134.origin); v76 = (char *)&v132[-1].m_fBrVertexMod; if ( (__int64 *)&v132[-1].m_fBrVertexMod != &qword_124B6B0 ) { if ( &pthread_create ) { v77 = (unsigned int *)&v132[-1].m_fTextureTop; do v78 = __ldaxr(v77); while ( __stlxr(v78 - 1, v77) ); } else { v78 = LODWORD(v132[-1].m_fTextureTop); LODWORD(v132[-1].m_fTextureTop) = v78 - 1; } if ( v78 <= 0 ) operator delete(v76); } } } BrowserItem = GJItemIcon::createBrowserItem(a3, a2); BrowserItem->setScale(BrowserItem, 1.25); a1->m_mainLayer->addChild_0(a1->m_mainLayer, BrowserItem, 12); v19 = BrowserItem->setPosition; cocos2d::CCPoint::CCPoint(&v133, 0.0, 56.0); cocos2d::CCPoint::operator+(&v134, &v124, &v133); v19(BrowserItem, &v134.origin); v20 = cocos2d::CCMenu::create(); m_mainLayer = a1->m_mainLayer; a1->m_buttonMenu = v20; m_mainLayer->addChild_0(m_mainLayer, v20, 10); v28 = (cocos2d::CCNode *)ButtonSprite::create((ButtonSprite *)"OK", v22, v23, v24, v25, v26, v27); v136.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v136.adj = (size_t)ItemInfoPopup::onClose; v29 = CCMenuItemSpriteExtra::create(v28, nullptr, v136); a1->m_buttonMenu->addChild(a1->m_buttonMenu, v29); m_buttonMenu = a1->m_buttonMenu; v31 = m_buttonMenu->setPosition; cocos2d::CCPoint::CCPoint(&v134.origin, v122 * 0.5, (float)((float)(v123 * 0.5) + -115.0) + 25.0); v31(m_buttonMenu, &v134.origin); v32 = GameStatsManager::sharedState(); ItemUnlockState = GameStatsManager::getItemUnlockState(v32, a2, a3); v34 = GameManager::sharedState(); v35 = GameManager::sharedState(); v36 = GameManager::unlockTypeToIconType(v35, a3); isIconUnlocked = GameManager::isIconUnlocked(v34, a2, v36); v117 = isIconUnlocked; sub_D153B8((int)&v129, &byte_F288A0); sub_D153B8((int)&v130, &byte_F288A0); sub_D153B8((int)&v131, &byte_F288A0); switch ( ItemUnlockState ) { case 5: sub_D1798C(&v131, "Secret Shop", 11); v81 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"There may or may not exist a shop where you can buy<" "/c> this %s.", v126); LABEL_70: v112 = cocos2d::CCString::getCString(v81); v82 = strlen(v112); sub_D1798C(&v129, v112, v82); break; case 6: sub_D1798C(&v131, "Community Shop", 14); v81 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"You can buy this %s in the community shop!", v126); goto LABEL_70; case 7: sub_D1798C(&v131, "Mechanic Shop", 13); v81 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"You can buy this %s at the Mechanic!", v126); goto LABEL_70; case 8: sub_D1798C(&v131, "Diamond Shop", 12); v81 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"You can buy this %s in the diamond shop!", v126); goto LABEL_70; case 4: sub_D1798C(&v131, "Shop", 4); v81 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"You can buy this %s in the shop!", v126); goto LABEL_70; case 2: sub_D1798C(&v131, "Secret Chest", 12); v100 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"You can find this %s in a secret chest!", v126); v113 = cocos2d::CCString::getCString(v100); v101 = strlen(v113); sub_D1798C(&v129, v113, v101); sub_D1798C(&v130, &byte_F288A0, 0); v102 = (int)(float)((float)((float)rand() * 4.6566e-10) * 10.0) - 1; switch ( v102 ) { case 0: sub_D1798C(&v130, "Nothing happened.", 17); break; case 1: sub_D1798C(&v130, "Without a key, it cannot be.", 28); break; case 2: sub_D1798C(&v130, "Why you click?", 14); break; case 3: sub_D1798C(&v130, "You are not yet ready.", 22); break; case 4: sub_D1798C(&v130, "A key, you must have.", 21); break; case 5: sub_D1798C(&v130, "The lock wont budge.", 20); break; case 6: sub_D1798C(&v130, "A demon guards it. Find him.", 28); break; case 7: sub_D1798C(&v130, "You have no power here.", 23); break; case 8: sub_D1798C(&v130, "Forget about this one.", 22); break; default: sub_D1798C(&v130, "A key... My kingdom for a key...", 32); break; } break; case 3: sub_D1798C(&v131, "Special Chest", 13); v103 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"You can find this %s in a special chest!", v126); v114 = cocos2d::CCString::getCString(v103); v104 = strlen(v114); sub_D1798C(&v129, v114, v104); sub_D1798C(&v130, &byte_F288A0, 0); v105 = (int)(float)((float)((float)rand() * 4.6566e-10) * 10.0) - 1; switch ( v105 ) { case 0: sub_D1798C(&v130, "That wont work.", 15); break; case 1: sub_D1798C(&v130, "You must do something.", 22); break; case 2: sub_D1798C(&v130, "It cannot be done.", 18); break; case 3: sub_D1798C(&v130, "Prove that you are worthy.", 26); break; case 4: sub_D1798C(&v130, "Need. More. Power.", 18); break; case 5: sub_D1798C(&v130, "Player used tap.\nIt's not very effective.", 41); break; case 6: sub_D1798C(&v130, "A wild lock appeared!", 21); break; case 7: sub_D1798C(&v130, "You are not ready.", 18); break; case 8: sub_D1798C(&v130, "ehehehehehe...", 14); break; default: sub_D1798C(&v130, "IMPOSSIBRU!", 11); break; } break; case 1: GJGarageLayer::titleForUnlock(a2, a3, (__int64)&v133); sub_D163D4(&v131, &v133); v54 = (void *)(*(_QWORD *)&v133 - 24LL); if ( (__int64 *)(*(_QWORD *)&v133 - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v110 = (unsigned int *)(*(_QWORD *)&v133 - 8LL); do v111 = __ldaxr(v110); while ( __stlxr(v111 - 1, v110) ); } else { v111 = *(_DWORD *)(*(_QWORD *)&v133 - 8LL); *(_DWORD *)(*(_QWORD *)&v133 - 8LL) = v111 - 1; } if ( v111 <= 0 ) operator delete(v54); } GJGarageLayer::descriptionForUnlock(a2, a3, (__int64)&v134); v55 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%s to unlock this %s!", *(const char **)&v134.origin, v126); v119 = cocos2d::CCString::getCString(v55); v56 = strlen(v119); sub_D1798C(&v129, v119, v56); v57 = (void *)(*(_QWORD *)&v134.origin - 24LL); if ( (__int64 *)(*(_QWORD *)&v134.origin - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v58 = (unsigned int *)(*(_QWORD *)&v134.origin - 8LL); do v59 = __ldaxr(v58); while ( __stlxr(v59 - 1, v58) ); } else { v59 = *(_DWORD *)(*(_QWORD *)&v134.origin - 8LL); *(_DWORD *)(*(_QWORD *)&v134.origin - 8LL) = v59 - 1; } if ( v59 <= 0 ) operator delete(v57); } goto LABEL_20; } v37 = GameStatsManager::sharedState(); GameStatsManager::getSpecialUnlockDescription(v37, a2, a3, isIconUnlocked); origin = v134.origin; if ( *(_QWORD *)(*(_QWORD *)&v134.origin - 24LL) ) { v79 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%s to unlock this %s!", *(const char **)&v134.origin, v126); v116 = cocos2d::CCString::getCString(v79); v80 = strlen(v116); sub_D1798C(&v129, v116, v80); sub_D1798C(&v130, &byte_F288A0, 0); origin = v134.origin; } v39 = (void *)(*(_QWORD *)&origin - 24LL); if ( (__int64 *)(*(_QWORD *)&origin - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v98 = (unsigned int *)(*(_QWORD *)&origin - 8LL); do v99 = __ldaxr(v98); while ( __stlxr(v99 - 1, v98) ); } else { v99 = *(_DWORD *)(*(_QWORD *)&origin - 8LL); *(_DWORD *)(*(_QWORD *)&origin - 8LL) = v99 - 1; } if ( v99 <= 0 ) operator delete(v39); } if ( v117 ) { if ( !ItemUnlockState && ItemInfoPopup::isUnlockedByDefault(a1, a2, a3) ) { sub_D1798C(&v131, "Default", 7); v40 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"This %s is unlocked by default.", v126); LABEL_19: v118 = cocos2d::CCString::getCString(v40); v41 = strlen(v118); sub_D1798C(&v129, v118, v41); } } else if ( !ItemUnlockState ) { if ( *(_QWORD *)(v129 - 24) ) { LABEL_48: sub_D18D28(&v134); cocos2d::CCPoint::CCPoint(&v133, 0.5, 1.0); v60 = (cocos2d::CCNode *)TextArea::create((__int64)&v134, "bigFont.fnt", &v133, 0, 1.0, 600.0, 42.0); v61 = (void *)(*(_QWORD *)&v134.origin - 24LL); if ( (__int64 *)(*(_QWORD *)&v134.origin - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v106 = (unsigned int *)(*(_QWORD *)&v134.origin - 8LL); do v107 = __ldaxr(v106); while ( __stlxr(v107 - 1, v106) ); } else { v107 = *(_DWORD *)(*(_QWORD *)&v134.origin - 8LL); *(_DWORD *)(*(_QWORD *)&v134.origin - 8LL) = v107 - 1; } if ( v107 <= 0 ) operator delete(v61); } a1->m_mainLayer->addChild_0(a1->m_mainLayer, v60, 10); v62 = v60->setPosition; cocos2d::CCPoint::CCPoint(&v133, 0.0, -2.0); cocos2d::CCPoint::operator+(&v134, &v125, &v133); v62(v60, &v134.origin); v60->setScale(v60, 0.4); if ( v130[-1].m_pTargetArray ) { v63 = cocos2d::CCLabelBMFont::create(); v120 = v63->setPosition; cocos2d::CCPoint::CCPoint(&v133, 0.0, -35.0); cocos2d::CCPoint::operator+(&v134, &v125, &v133); v120(v63, &v134.origin); a1->m_mainLayer->addChild(a1->m_mainLayer, v63); v63->setScale(v63, 0.6); v63->setColor(v63, (const cocos2d::ccColor3B *)&unk_ECEDE0); v63->setOpacity(v63, 75); v121 = v60->setPosition; v64 = (__int64)v60->getPosition(v60); cocos2d::CCPoint::CCPoint(&v133, 0.0, 5.0); cocos2d::CCPoint::operator+(&v134, v64, &v133); v121(v60, &v134.origin); } goto LABEL_21; } switch ( llroundf((float)((float)rand() * 4.6566e-10) * 10.0) ) { case 1u: sub_D1798C(&v131, "Not yet", 7); break; case 2u: sub_D1798C(&v131, "Huh?", 4); break; case 3u: sub_D1798C(&v131, "Stay tuned!", 11); break; case 4u: sub_D1798C(&v131, "Coming soon!", 12); break; case 5u: sub_D1798C(&v131, "In the oven", 11); break; case 6u: sub_D1798C(&v131, "It's cooking", 12); break; case 7u: sub_D1798C(&v131, "Wait for it", 11); break; case 8u: sub_D1798C(&v131, "Not now", 7); break; case 9u: sub_D1798C(&v131, "Unavailable", 11); break; case 0xAu: sub_D1798C(&v131, "Almost there", 12); break; default: sub_D1798C(&v131, "Soon...", 7); break; } v40 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"This %s can be unlocked in update 2.21.", v126); goto LABEL_19; } LABEL_20: if ( *(_QWORD *)(v129 - 24) ) goto LABEL_48; LABEL_21: if ( v131[-1].m_pTargetArray ) { v42 = cocos2d::CCLabelBMFont::create(); v43 = v42->setPosition; cocos2d::CCPoint::CCPoint(&v133, 0.0, 30.0); cocos2d::CCPoint::operator+(&v134, &v125, &v133); v43(v42, &v134.origin); a1->m_mainLayer->addChild(a1->m_mainLayer, v42); cocos2d::CCLabelBMFont::limitLabelWidth(v42, 180.0, 0.55, 0.0); if ( ItemUnlockState == 4 ) v42->setScale(v42, 0.6); } v44 = GameStatsManager::sharedState(); v45 = GameStatsManager::accountIDForIcon(v44, a2, a3); a1->m_accountID = v45; if ( v45 ) { v65 = GameStatsManager::sharedState(); GameStatsManager::usernameForAccountID((__int64 *)&v132, v65, a1->m_accountID); v66 = v132; if ( *(_QWORD *)&v132[-1].m_fBrVertexMod ) { v93 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"By %s", (const char *)v132); cocos2d::CCString::getCString(v93); v94 = cocos2d::CCLabelBMFont::create(); cocos2d::CCPoint::CCPoint( &v133, (float)((float)(v122 * 0.5) + 150.0) - 60.0, (float)((float)(v123 * 0.5) + -115.0) + 21.0); cocos2d::CCLabelBMFont::limitLabelWidth(v94, 100.0, 0.5, 0.0); v137.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v137.adj = (size_t)ItemInfoPopup::onCredit; v95 = CCMenuItemSpriteExtra::create(v94, nullptr, v137); a1->m_buttonMenu->addChild(a1->m_buttonMenu, v95); v96 = v95->setPosition; v135 = cocos2d::CCNode::convertToNodeSpace(a1->m_buttonMenu, &v133); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCRect *, float, float))v96)(v95, &v134, v135.x, v135.y); if ( a1->m_accountID <= 0 ) { setColor = v94->setColor; LOWORD(v134.origin.x) = -166; BYTE2(v134.origin.x) = -1; setColor(v94, (const cocos2d::ccColor3B *)&v134); v95->setEnabled(v95, 0); } v66 = v132; } v67 = &v66[-1].m_fBrVertexMod; if ( (__int64 *)&v66[-1].m_fBrVertexMod != &qword_124B6B0 ) { if ( &pthread_create ) { v68 = (unsigned int *)&v66[-1].m_fTextureTop; do v69 = __ldaxr(v68); while ( __stlxr(v69 - 1, v68) ); } else { v69 = LODWORD(v66[-1].m_fTextureTop); LODWORD(v66[-1].m_fTextureTop) = v69 - 1; } if ( v69 <= 0 ) operator delete(v67); } } p_m_pTargetArray = &v131[-1].m_pTargetArray; if ( &v131[-1].m_pTargetArray != (cocos2d::CCArray **)&qword_124B6B0 ) { if ( &pthread_create ) { p_m_nExtraKerning = (unsigned int *)&v131[-1].m_nExtraKerning; do m_nExtraKerning = __ldaxr(p_m_nExtraKerning); while ( __stlxr(m_nExtraKerning - 1, p_m_nExtraKerning) ); } else { m_nExtraKerning = v131[-1].m_nExtraKerning; v131[-1].m_nExtraKerning = m_nExtraKerning - 1; } if ( m_nExtraKerning <= 0 ) operator delete(p_m_pTargetArray); } v47 = &v130[-1].m_pTargetArray; if ( &v130[-1].m_pTargetArray != (cocos2d::CCArray **)&qword_124B6B0 ) { if ( &pthread_create ) { v89 = (unsigned int *)&v130[-1].m_nExtraKerning; do v90 = __ldaxr(v89); while ( __stlxr(v90 - 1, v89) ); } else { v90 = v130[-1].m_nExtraKerning; v130[-1].m_nExtraKerning = v90 - 1; } if ( v90 <= 0 ) operator delete(v47); } v48 = (void *)(v129 - 24); if ( (__int64 *)(v129 - 24) != &qword_124B6B0 ) { if ( &pthread_create ) { v85 = (unsigned int *)(v129 - 8); do v86 = __ldaxr(v85); while ( __stlxr(v86 - 1, v85) ); } else { v86 = *(_DWORD *)(v129 - 8); *(_DWORD *)(v129 - 8) = v86 - 1; } if ( v86 <= 0 ) operator delete(v48); } v49 = (void *)(v128 - 24); if ( (__int64 *)(v128 - 24) != &qword_124B6B0 ) { if ( &pthread_create ) { v83 = (unsigned int *)(v128 - 8); do v84 = __ldaxr(v83); while ( __stlxr(v84 - 1, v83) ); } else { v84 = *(_DWORD *)(v128 - 8); *(_DWORD *)(v128 - 8) = v84 - 1; } if ( v84 <= 0 ) operator delete(v49); } v50 = &v127[-1].m_pTargetArray; if ( &v127[-1].m_pTargetArray != (cocos2d::CCArray **)&qword_124B6B0 ) { if ( &pthread_create ) { v87 = (unsigned int *)&v127[-1].m_nExtraKerning; do v88 = __ldaxr(v87); while ( __stlxr(v88 - 1, v87) ); } else { v88 = v127[-1].m_nExtraKerning; v127[-1].m_nExtraKerning = v88 - 1; } if ( v88 <= 0 ) operator delete(v50); } v51 = v126 - 24; if ( v126 - 24 != (char *)&qword_124B6B0 ) { if ( &pthread_create ) { v52 = (unsigned int *)(v126 - 8); do v53 = __ldaxr(v52); while ( __stlxr(v53 - 1, v52) ); } else { v53 = *((_DWORD *)v126 - 2); *((_DWORD *)v126 - 2) = v53 - 1; } if ( v53 <= 0 ) operator delete(v51); } return v6; }
GD Web Decomp Icon

GD Web Decomp

Raw Source