//
// LevelInfoLayer::updateLabelValues from 0x10002cb74 to 0x10002d528 (2484 bytes)
//
// 3 xrefs:
// > sub_10002A788 @ 0x10002b1b8
// > LevelInfoLayer::levelDownloadFinished @ 0x10002d608
// > LevelInfoLayer::likedItem @ 0x10002e58c
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 10:57:29 +0000
//
void __fastcall LevelInfoLayer::updateLabelValues(__int64 a1)
{
__int64 v1; // x20
const std::string::value_type *p_p; // x1
std::string *v4; // x1
__int64 v5; // x20
std::string *v6; // x1
__int64 v7; // x20
std::string *v8; // x1
__int64 v9; // x0
__int64 v10; // x20
__int64 v11; // x21
__int64 v12; // x22
__int64 v13; // x0
__int64 isDailyRecall; // x0
char v15; // w1
__int64 v16; // x20
__int64 v17; // x0
__int64 CString; // x0
__int64 v19; // x20
__int16 v20; // w8
int v21; // w20
__int64 v22; // x21
std::string *v23; // x1
__int64 v24; // x0
__int64 v25; // x21
__int64 v26; // x0
const char *v27; // x1
__int64 v28; // x0
__int64 v29; // x0
__int64 v30; // x0
__int64 v31; // x0
__int64 v32; // x0
__int64 v33; // x0
__int64 v34; // x0
__int64 v35; // x0
__int64 v36; // x0
__n128 v37; // q0
unsigned int AverageDifficulty; // w20
double v39; // d0
__int64 v40; // x8
__int64 v41; // x1
__int64 v42; // x20
__int64 v43; // x0
__int64 v44; // x0
__int64 v45; // x0
__int64 v46; // x0
__int64 v47; // x0
__int64 v48; // x8
int v49; // w21
int v50; // w22
float v51; // s9
__int64 v52; // x20
float *v53; // x0
__int64 v54; // x20
float *v55; // x0
int v56; // w20
char v57; // w21
float v58; // s8
__int64 v59; // x20
__int64 v60; // x21
float32x2_t *v61; // x22
double v62; // d0
__int64 v63; // x20
__int64 v64; // x0
_DWORD *v65; // x0
int v66; // w8
int HasDiamonds; // w0
float v68; // s0
_DWORD *v69; // x0
int v70; // w25
int v71; // w20
float v72; // s8
float v73; // s9
float v74; // s0
char *CoinKey_1; // x0
_QWORD *v76; // x0
__int64 v77; // x0
std::string *v78; // x1
__int64 hasUserCoin; // x0
int hasPendingUserCoin; // w23
__int64 v81; // x0
std::string *v82; // x1
__int64 v83; // x22
double v84; // d0
int v85; // w8
float32x2_t v86; // [xsp+18h] [xbp-C8h] BYREF
float32x2_t v87; // [xsp+20h] [xbp-C0h] BYREF
__int64 v88; // [xsp+28h] [xbp-B8h] BYREF
void *__p; // [xsp+30h] [xbp-B0h] BYREF
char v90; // [xsp+38h] [xbp-A8h]
char v91; // [xsp+47h] [xbp-99h]
std::string v92; // [xsp+48h] [xbp-98h] BYREF
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 568) + 344LL))(*(_QWORD *)(a1 + 568), 0);
if ( (unsigned int)GJGameLevel::isPlatformer(*(_QWORD *)(a1 + 504)) )
{
LODWORD(v1) = vcvtms_s32_f32((float)*(int *)(*(_QWORD *)(a1 + 504) + 1232LL) / 240.0);
sub_100009900(&v92, "<1min");
if ( (int)v1 < 61 )
{
if ( !(_DWORD)v1 )
std::string::assign(&v92, "Dur.");
}
else
{
sub_10004AFB4(&__p, v1, 1);
if ( v91 >= 0 )
p_p = (const std::string::value_type *)&__p;
else
p_p = (const std::string::value_type *)__p;
std::string::assign(&v92, p_p);
if ( v91 < 0 )
operator delete(__p);
}
if ( (v92.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v4 = &v92;
else
v4 = (std::string *)v92.__r_.__value_.__r.__words[0];
(*(void (__fastcall **)(_QWORD, std::string *))(**(_QWORD **)(a1 + 568) + 928LL))(*(_QWORD *)(a1 + 568), v4);
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 568) + 344LL))(*(_QWORD *)(a1 + 568), 1);
if ( SHIBYTE(v92.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v92.__r_.__value_.__l.__data_);
}
v5 = *(_QWORD *)(a1 + 560);
GJGameLevel::lengthKeyToString(&v92, *(unsigned int *)(*(_QWORD *)(a1 + 504) + 900LL));
if ( (v92.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v6 = &v92;
else
v6 = (std::string *)v92.__r_.__value_.__r.__words[0];
(*(void (__fastcall **)(__int64, std::string *))(*(_QWORD *)v5 + 928LL))(v5, v6);
if ( SHIBYTE(v92.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v92.__r_.__value_.__l.__data_);
v7 = *(_QWORD *)(a1 + 576);
GameToolbox::pointsToString(&v92);
if ( (v92.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v8 = &v92;
else
v8 = (std::string *)v92.__r_.__value_.__r.__words[0];
v9 = (*(__int64 (__fastcall **)(__int64, std::string *))(*(_QWORD *)v7 + 928LL))(v7, v8);
if ( SHIBYTE(v92.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v92.__r_.__value_.__l.__data_);
v10 = GameStatsManager::sharedState(v9);
v11 = *(_QWORD *)(a1 + 504);
v12 = (unsigned int)(*(_DWORD *)(v11 + 920) - *(_DWORD *)(v11 + 924));
v13 = GameStatsManager::sharedState(v10);
isDailyRecall = GameStatsManager::isDailyRecall(
v13,
(unsigned int)(*(_DWORD *)(*(_QWORD *)(a1 + 504) + 920LL)
- *(_DWORD *)(*(_QWORD *)(a1 + 504) + 924LL)));
__p = (void *)sub_1003D079C(v10, v11, v12, isDailyRecall);
v90 = v15;
v16 = *(_QWORD *)(a1 + 592);
v17 = sub_1003065B0("%i/%i", (_DWORD)__p, HIDWORD(__p));
CString = cocos2d::CCString::getCString(v17);
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v16 + 928LL))(v16, CString);
v19 = *(_QWORD *)(a1 + 592);
if ( (unsigned int)sub_1003D0800(&__p) )
{
v92.__r_.__value_.__s.__data_[2] = -106;
v20 = -26986;
}
else
{
v20 = -1;
v92.__r_.__value_.__s.__data_[2] = -1;
}
LOWORD(v92.__r_.__value_.__l.__data_) = v20;
(*(void (__fastcall **)(__int64, std::string *))(*(_QWORD *)v19 + 1072LL))(v19, &v92);
v21 = *(_DWORD *)(*(_QWORD *)(a1 + 504) + 892LL) - *(_DWORD *)(*(_QWORD *)(a1 + 504) + 896LL);
v22 = *(_QWORD *)(a1 + 584);
GameToolbox::pointsToString(&v92);
if ( (v92.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v23 = &v92;
else
v23 = (std::string *)v92.__r_.__value_.__r.__words[0];
v24 = (*(__int64 (__fastcall **)(__int64, std::string *))(*(_QWORD *)v22 + 928LL))(v22, v23);
if ( SHIBYTE(v92.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v92.__r_.__value_.__l.__data_);
v25 = *(_QWORD *)(a1 + 624);
v26 = cocos2d::CCSpriteFrameCache::sharedSpriteFrameCache(v24);
if ( v21 < 0 )
v27 = "GJ_dislikesIcon_001.png";
else
v27 = "GJ_likesIcon_001.png";
v28 = cocos2d::CCSpriteFrameCache::spriteFrameByName(v26, v27);
v29 = (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v25 + 1160LL))(v25, v28);
v30 = GameManager::sharedState(v29);
if ( *(_DWORD *)(v30 + 660) - *(_DWORD *)(v30 + 664) == *(_DWORD *)(*(_QWORD *)(a1 + 504) + 576LL)
- *(_DWORD *)(*(_QWORD *)(a1 + 504) + 580LL) )
{
if ( v21 >= 50 )
{
v31 = GameManager::sharedState(v30);
v30 = GameManager::reportAchievementWithID(v31, "geometry.ach.creator03", 100, 0);
if ( (unsigned int)v21 >= 0x64 )
{
v32 = GameManager::sharedState(v30);
v30 = GameManager::reportAchievementWithID(v32, "geometry.ach.creator01", 100, 0);
if ( (unsigned int)v21 >= 0xFA )
{
v33 = GameManager::sharedState(v30);
v30 = GameManager::reportAchievementWithID(v33, "geometry.ach.creator04", 100, 0);
if ( (unsigned int)v21 >= 0x1F4 )
{
v34 = GameManager::sharedState(v30);
v30 = GameManager::reportAchievementWithID(v34, "geometry.ach.creator05", 100, 0);
if ( (unsigned int)v21 >= 0x3E8 )
{
v35 = GameManager::sharedState(v30);
v30 = GameManager::reportAchievementWithID(v35, "geometry.ach.creator06", 100, 0);
}
}
}
}
}
if ( *(_DWORD *)(*(_QWORD *)(a1 + 504) + 948LL) > *(_DWORD *)(*(_QWORD *)(a1 + 504) + 952LL) )
{
v36 = GameManager::sharedState(v30);
GameManager::reportAchievementWithID(v36, "geometry.ach.creator02", 100, 0);
}
}
cocos2d::CCLabelBMFont::limitLabelWidth(*(_QWORD *)(a1 + 560), 60.0, 0.5, 0.0);
cocos2d::CCLabelBMFont::limitLabelWidth(*(_QWORD *)(a1 + 568), 42.0, 0.35, 0.0);
cocos2d::CCLabelBMFont::limitLabelWidth(*(_QWORD *)(a1 + 576), 60.0, 0.5, 0.0);
cocos2d::CCLabelBMFont::limitLabelWidth(*(_QWORD *)(a1 + 584), 60.0, 0.5, 0.0);
v37 = cocos2d::CCLabelBMFont::limitLabelWidth(*(_QWORD *)(a1 + 592), 60.0, 0.5, 0.0);
AverageDifficulty = GJGameLevel::getAverageDifficulty(*(_QWORD *)(a1 + 504), v37);
v39 = sub_1000262F4(&v88, (double *)(a1 + 692));
v40 = *(_QWORD *)(a1 + 504);
if ( *(_DWORD *)(v40 + 932) - *(_DWORD *)(v40 + 936) == 1 )
{
AverageDifficulty = GJGameLevel::demonIconForDifficulty(*(unsigned int *)(v40 + 944), v39);
*((float *)&v88 + 1) = *((float *)&v88 + 1) + 5.0;
v40 = *(_QWORD *)(a1 + 504);
}
if ( *(_BYTE *)(v40 + 960) )
v41 = 0xFFFFFFFFLL;
else
v41 = AverageDifficulty;
GJDifficultySprite::updateDifficultyFrame(*(_QWORD *)(a1 + 656), v41, 1);
(*(void (__fastcall **)(_QWORD, __int64 *))(**(_QWORD **)(a1 + 656) + 184LL))(*(_QWORD *)(a1 + 656), &v88);
GJDifficultySprite::updateFeatureStateFromLevel(*(_QWORD *)(a1 + 656), *(_QWORD *)(a1 + 504));
v42 = *(_QWORD *)(a1 + 672);
v43 = sub_1003065B0("%i", *(_DWORD *)(*(_QWORD *)(a1 + 504) + 948LL) - *(_DWORD *)(*(_QWORD *)(a1 + 504) + 952LL));
v44 = cocos2d::CCString::getCString(v43);
v45 = (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v42 + 928LL))(v42, v44);
v46 = GameStatsManager::sharedState(v45);
if ( (unsigned int)sub_1003CEC70(v46, *(_QWORD *)(a1 + 504)) )
{
v47 = *(_QWORD *)(a1 + 672);
v92.__r_.__value_.__s.__data_[2] = 50;
LOWORD(v92.__r_.__value_.__l.__data_) = -1;
(*(void (__fastcall **)(__int64, std::string *))(*(_QWORD *)v47 + 1072LL))(v47, &v92);
}
v48 = *(_QWORD *)(a1 + 504);
v49 = *(_DWORD *)(v48 + 948);
v50 = *(_DWORD *)(v48 + 952);
(*(void (__fastcall **)(_QWORD, bool))(**(_QWORD **)(a1 + 672) + 344LL))(*(_QWORD *)(a1 + 672), v49 > v50);
(*(void (__fastcall **)(_QWORD, bool))(**(_QWORD **)(a1 + 664) + 344LL))(*(_QWORD *)(a1 + 664), v49 > v50);
if ( *(_DWORD *)(*(_QWORD *)(a1 + 504) + 932LL) - *(_DWORD *)(*(_QWORD *)(a1 + 504) + 936LL) == 1 )
v51 = -4.0;
else
v51 = 0.0;
v52 = *(_QWORD *)(a1 + 672);
v53 = (float *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v52 + 192LL))(v52);
sub_1000262BC((float *)&v92, *v53, v51 + *(float *)(a1 + 700));
(*(void (__fastcall **)(__int64, std::string *))(*(_QWORD *)v52 + 184LL))(v52, &v92);
v54 = *(_QWORD *)(a1 + 664);
v55 = (float *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v54 + 192LL))(v54);
sub_1000262BC((float *)&v92, *v55, v51 + *(float *)(a1 + 700));
(*(void (__fastcall **)(__int64, std::string *))(*(_QWORD *)v54 + 184LL))(v54, &v92);
v56 = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 592) + 352LL))(*(_QWORD *)(a1 + 592));
if ( v49 <= v50 )
v57 = 0;
else
v57 = *(_BYTE *)(a1 + 704) ^ 1;
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 592) + 344LL))(*(_QWORD *)(a1 + 592), v57 & 1);
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 632) + 344LL))(*(_QWORD *)(a1 + 632), v57 & 1);
if ( v56 != (*(unsigned int (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 592) + 352LL))(*(_QWORD *)(a1 + 592)) )
{
v58 = (*(unsigned int (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 592) + 352LL))(*(_QWORD *)(a1 + 592))
? *(float *)(a1 + 688)
: -*(float *)(a1 + 688);
if ( (unsigned int)sub_1002E757C(*(_QWORD *)(a1 + 680)) )
{
v59 = 0;
do
{
v60 = sub_1002E75A0(*(_QWORD *)(a1 + 680), v59);
v61 = (float32x2_t *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v60 + 192LL))(v60);
sub_1000262BC((float *)&v87, 0.0, v58);
*(float32x2_t *)&v62 = sub_100026318(v61, &v87, (float32x2_t *)&v92);
(*(void (__fastcall **)(__int64, std::string *, double))(*(_QWORD *)v60 + 184LL))(v60, &v92, v62);
v59 = (unsigned int)(v59 + 1);
}
while ( (unsigned int)v59 < (unsigned int)sub_1002E757C(*(_QWORD *)(a1 + 680)) );
}
}
if ( (unsigned int)sub_1002E757C(*(_QWORD *)(a1 + 512)) )
{
v63 = 0;
do
{
v64 = sub_1002E75A0(*(_QWORD *)(a1 + 512), v63);
(*(void (__fastcall **)(__int64))(*(_QWORD *)v64 + 520LL))(v64);
v63 = (unsigned int)(v63 + 1);
}
while ( (unsigned int)v63 < (unsigned int)sub_1002E757C(*(_QWORD *)(a1 + 512)) );
}
sub_1002E7674(*(_QWORD *)(a1 + 512));
v65 = *(_DWORD **)(a1 + 504);
v66 = v65[241];
if ( v66 > 0 )
{
if ( v65[237] <= v65[238] )
{
v70 = v65[242] - v65[243];
v68 = -31.5;
LABEL_75:
v71 = 0;
v72 = v51 + v68;
do
{
if ( v71 == 2 )
{
v73 = 10.0;
}
else if ( v71 == 1 )
{
if ( v66 == 2 )
v73 = 5.0;
else
v73 = 0.0;
}
else
{
if ( (unsigned int)v66 <= 2 )
v74 = 0.0;
else
v74 = -10.0;
if ( v66 == 2 )
v73 = -5.0;
else
v73 = v74;
}
++v71;
CoinKey_1 = (char *)GJGameLevel::getCoinKey_1();
v76 = sub_100009900(&v92, CoinKey_1);
v77 = GameStatsManager::sharedState(v76);
if ( (v92.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v78 = &v92;
else
v78 = (std::string *)v92.__r_.__value_.__r.__words[0];
hasUserCoin = GameStatsManager::hasUserCoin(v77, v78);
if ( (hasUserCoin & 1) != 0 )
{
hasPendingUserCoin = 1;
}
else
{
v81 = GameStatsManager::sharedState(hasUserCoin);
if ( (v92.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v82 = &v92;
else
v82 = (std::string *)v92.__r_.__value_.__r.__words[0];
hasPendingUserCoin = GameStatsManager::hasPendingUserCoin(v81, v82);
}
v83 = cocos2d::CCSprite::createWithSpriteFrameName("usercoin_small01_001.png");
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)a1 + 456LL))(a1, v83);
sub_1000262BC((float *)&v86, v73, v72);
*(float32x2_t *)&v84 = sub_100026318((float32x2_t *)(a1 + 692), &v86, &v87);
(*(void (__fastcall **)(__int64, float32x2_t *, double))(*(_QWORD *)v83 + 184LL))(v83, &v87, v84);
sub_1002E74E0(*(_QWORD *)(a1 + 512), v83);
if ( v70 == 1 )
{
if ( (hasPendingUserCoin & 1) == 0 )
{
v87.i8[2] = -91;
v87.i16[0] = -23131;
(*(void (__fastcall **)(__int64, float32x2_t *))(*(_QWORD *)v83 + 960LL))(v83, &v87);
}
}
else
{
v85 = 4960255;
if ( !hasPendingUserCoin )
v85 = 3174821;
v87.i16[0] = v85;
v87.i8[2] = BYTE2(v85);
(*(void (__fastcall **)(__int64, float32x2_t *))(*(_QWORD *)v83 + 960LL))(v83, &v87);
}
if ( SHIBYTE(v92.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v92.__r_.__value_.__l.__data_);
if ( (unsigned int)(v71 - 1) > 1 )
break;
v66 = *(_DWORD *)(*(_QWORD *)(a1 + 504) + 964LL);
}
while ( v71 < v66 );
return;
}
HasDiamonds = GJGameLevel::levelHasDiamonds(v65);
v68 = -45.5;
if ( HasDiamonds )
v68 = -60.0;
v69 = *(_DWORD **)(a1 + 504);
v66 = v69[241];
if ( v66 >= 1 )
{
v70 = v69[242] - v69[243];
goto LABEL_75;
}
}
}