// // GJGameLevel::dataLoaded from 0x14016dec0 to 0x14016eefb (4155 bytes) // // 3 xrefs: // > GJObjectDecoder::getDecodedObject @ 0x1402840e6 // > GJObjectDecoder::getDecodedObject @ 0x140284106 // > @ 0x1406cae3c // // 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=1 void GJGameLevel::dataLoaded(GJGameLevel *a1, DS_Dictionary *a2) { int v4; // ebx float v5; // xmm0_4 int v6; // ebx float v7; // xmm0_4 int v8; // ebx float v9; // xmm0_4 int v10; // ebx float v11; // xmm0_4 int v12; // ebx float v13; // xmm0_4 int v14; // ebx float v15; // xmm0_4 int v16; // ebx float v17; // xmm0_4 int v18; // ebx float v19; // xmm0_4 __int64 StringForKey; // rax __int64 v21; // rbx void *v22; // rdx int BoolForKey; // ebx float v24; // xmm0_4 int v25; // ebx float v26; // xmm0_4 int v27; // ebx float v28; // xmm0_4 __int64 v29; // rax __int64 v30; // rax __int64 v31; // rax __int64 v32; // rax __int64 v33; // rax __int64 v34; // rax __int64 v35; // rax __int64 v36; // rax __int64 v37; // rax __int64 v38; // rax float v39; // xmm6_4 int v40; // eax __int64 v41; // rax int v42; // eax int v43; // ebx float v44; // xmm0_4 int v45; // eax int v46; // ebx float v47; // xmm0_4 int v48; // eax int v49; // ebx float v50; // xmm0_4 GJDifficulty v51; // eax int v52; // eax int v53; // eax int v54; // eax int v55; // eax bool v56; // al BOOL v57; // ebx float v58; // xmm0_4 int v59; // eax int v60; // eax GJLevelType v61; // eax int v62; // eax int v63; // eax int v64; // eax int v65; // eax int v66; // eax int v67; // ebx float v68; // xmm0_4 int v69; // eax int v70; // ebx float v71; // xmm0_4 int v72; // eax int v73; // eax int v74; // eax int v75; // ebx float v76; // xmm0_4 __int64 v77; // rax int v78; // eax int v79; // eax int v80; // eax int v81; // eax __int64 v82; // rax __int64 v83; // rax int v84; // eax int v85; // eax float FloatForKey; // xmm6_4 float v87; // xmm0_4 __int64 v88; // rax int v89; // eax int v90; // eax int v91; // eax struct cocos2d::CCDictionary *DictForKey; // rax cocos2d::CCDictionary *v93; // rbx cocos2d::CCDictionary *m_lastBuildSave; // rcx int v95; // ebx float v96; // xmm0_4 int v97; // ebx float v98; // xmm0_4 int v99; // ebx float v100; // xmm0_4 __int64 v101; // rax int v102; // eax int v103; // r14d std::string *p_m_levelString; // rcx std::size_t m_size; // rsi size_t v106; // r8 __int64 v107; // rax __int64 v108; // rax __int64 v109; // rbx void *v110; // rcx __int64 v111; // [rsp+28h] [rbp-49h] BYREF _BYTE v112[32]; // [rsp+30h] [rbp-41h] BYREF __int128 Buf2; // [rsp+50h] [rbp-21h] BYREF __int128 v114; // [rsp+60h] [rbp-11h] a1->m_levelNotDownloaded = DS_Dictionary::getBoolForKey(a2, "k35"); v4 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k1"); a1->m_levelID.value = v4; v5 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_levelID.seed = (int)v5; a1->m_levelID.random = (int)v5 + v4; v6 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k18"); a1->m_attempts.value = v6; v7 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_attempts.seed = (int)v7; a1->m_attempts.random = (int)v7 + v6; v8 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k19"); a1->m_normalPercent.value = v8; v9 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_normalPercent.seed = (int)v9; a1->m_normalPercent.random = (int)v9 + v8; v10 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k71"); a1->m_orbCompletion.value = v10; v11 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_orbCompletion.seed = (int)v11; a1->m_orbCompletion.random = (int)v11 + v10; v12 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k90"); a1->m_newNormalPercent2.value = v12; v13 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_newNormalPercent2.seed = (int)v13; a1->m_newNormalPercent2.random = (int)v13 + v12; a1->m_practicePercent = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k20"); v14 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k36"); a1->m_jumps.value = v14; v15 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_jumps.seed = (int)v15; a1->m_jumps.random = (int)v15 + v14; v16 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k85"); a1->m_clicks.value = v16; v17 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_clicks.seed = (int)v17; a1->m_clicks.random = (int)v17 + v16; v18 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k86"); a1->m_attemptTime.value = v18; v19 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_attemptTime.seed = (int)v19; a1->m_attemptTime.random = (int)v19 + v18; a1->m_chk = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k87"); StringForKey = DS_Dictionary::getStringForKey(a2, &Buf2, "k88"); v21 = StringForKey; v111 = StringForKey; if ( &a1->m_personalBests != (std::string *)StringForKey ) { v22 = (void *)StringForKey; if ( *(_QWORD *)(StringForKey + 24) > 0xFu ) v22 = *(void **)StringForKey; sub_14003CCE0((void **)&a1->m_personalBests, v22, *(_QWORD *)(StringForKey + 16)); } sub_14003A830(v21); a1->m_isChkValid = DS_Dictionary::getBoolForKey(a2, "k89"); a1->m_levelLength = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k23"); BoolForKey = DS_Dictionary::getBoolForKey(a2, "k25"); a1->m_demon.value = BoolForKey; v24 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_demon.seed = (int)v24; a1->m_demon.random = BoolForKey + (int)v24; a1->m_demonDifficulty = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k76"); v25 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k26"); a1->m_stars.value = v25; v26 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_stars.seed = (int)v26; a1->m_stars.random = (int)v26 + v25; v27 = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)(a2, "k74"); a1->m_dailyID.value = v27; v28 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_dailyID.seed = (int)v28; a1->m_dailyID.random = (int)v28 + v27; a1->m_isCompletionLegitimate = DS_Dictionary::getBoolForKey(a2, "k68"); a1->m_gauntletLevel = DS_Dictionary::getBoolForKey(a2, "k77"); a1->m_gauntletLevel2 = DS_Dictionary::getBoolForKey(a2, "k78"); a1->m_levelFavorited = DS_Dictionary::getBoolForKey(a2, "k82"); a1->m_levelFolder = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k84"); a1->m_bestTime = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k107"); a1->m_ticksTime = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k115"); a1->m_clicksTime = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k117"); a1->m_coinsTime = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k121"); v29 = DS_Dictionary::getStringForKey(a2, &Buf2, "k119"); sub_140051590((__int64)&a1->m_inputsTime, v29); sub_14003A830((__int64)&Buf2); a1->m_bestPoints = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k108"); a1->m_ticksPoints = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k116"); a1->m_clicksPoints = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k118"); a1->m_coinsPoints = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k122"); v30 = DS_Dictionary::getStringForKey(a2, &Buf2, "k120"); sub_140051590((__int64)&a1->m_inputsPoints, v30); sub_14003A830((__int64)&Buf2); a1->m_platformerSeed = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k111"); a1->m_savedTime = DS_Dictionary::getBoolForKey(a2, "k123"); a1->m_savedPoints = DS_Dictionary::getBoolForKey(a2, "k124"); v31 = DS_Dictionary::getStringForKey(a2, &Buf2, "k109"); sub_140051590((__int64)&a1->m_localBestTimes, v31); sub_14003A830((__int64)&Buf2); v32 = DS_Dictionary::getStringForKey(a2, &Buf2, "k110"); sub_140051590((__int64)&a1->m_localBestPoints, v32); sub_14003A830((__int64)&Buf2); if ( !a1->m_levelNotDownloaded ) { v33 = DS_Dictionary::getStringForKey(a2, &Buf2, "k2"); sub_140051590((__int64)&a1->m_levelName, v33); sub_14003A830((__int64)&Buf2); v34 = DS_Dictionary::getStringForKey(a2, &Buf2, "k3"); sub_140051590((__int64)&a1->m_levelDesc, v34); sub_14003A830((__int64)&Buf2); v35 = DS_Dictionary::getStringForKey(a2, &Buf2, "k4"); sub_140051590((__int64)&a1->m_levelString, v35); sub_14003A830((__int64)&Buf2); v36 = DS_Dictionary::getStringForKey(a2, &Buf2, "k5"); sub_140051590((__int64)&a1->m_creatorName, v36); sub_14003A830((__int64)&Buf2); a1->m_timestamp = ((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k95"); v37 = DS_Dictionary::getStringForKey(a2, &Buf2, "k91"); sub_140051590((__int64)&a1->m_lockedEditorLayers, v37); sub_14003A830((__int64)&Buf2); v38 = DS_Dictionary::getStringForKey(a2, &Buf2, "k101"); sub_140051590((__int64)&a1->m_savedCameraPositions, v38); sub_14003A830((__int64)&Buf2); v39 = (float)(int)((int (__fastcall *)(DS_Dictionary *__hidden, const char *))DS_Dictionary::getIntegerForKey)( a2, "k102"); DS_Dictionary::getIntegerForKey(a2, "k103"); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v111, v39, (float)v40); cocos2d::CCPoint::operator=(&a1->m_previewLock, v41); DS_Dictionary::getIntegerForKey(a2, "k64"); a1->m_coins = v42; v43 = DS_Dictionary::getBoolForKey(a2, "k65"); a1->m_coinsVerified.value = v43; v44 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_coinsVerified.seed = (int)v44; a1->m_coinsVerified.random = v43 + (int)v44; DS_Dictionary::getIntegerForKey(a2, "k6"); v46 = v45; a1->m_userID.value = v45; v47 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_userID.seed = (int)v47; a1->m_userID.random = (int)v47 + v46; DS_Dictionary::getIntegerForKey(a2, "k60"); v49 = v48; a1->m_accountID.value = v48; v50 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_accountID.seed = (int)v50; a1->m_accountID.random = (int)v50 + v49; DS_Dictionary::getIntegerForKey(a2, "k7"); a1->m_difficulty = v51; DS_Dictionary::getIntegerForKey(a2, "k8"); a1->m_audioTrack = v52; DS_Dictionary::getIntegerForKey(a2, "k9"); a1->m_ratings = v53; DS_Dictionary::getIntegerForKey(a2, "k10"); a1->m_ratingsSum = v54; DS_Dictionary::getIntegerForKey(a2, "k11"); a1->m_downloads = v55; a1->m_isEditable = DS_Dictionary::getBoolForKey(a2, "k13"); v56 = DS_Dictionary::getBoolForKey(a2, "k14"); v57 = v56; a1->m_isVerifiedRaw = v56; v58 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_isVerified.seed = (int)v58; a1->m_isVerified.random = (int)v58 + v57; a1->m_isUploaded = DS_Dictionary::getBoolForKey(a2, "k15"); DS_Dictionary::getIntegerForKey(a2, "k22"); a1->m_likes = v59; DS_Dictionary::getIntegerForKey(a2, "k24"); a1->m_dislikes = v60; DS_Dictionary::getIntegerForKey(a2, "k21"); a1->m_levelType = v61; DS_Dictionary::getIntegerForKey(a2, "k16"); a1->m_levelVersion = v62; DS_Dictionary::getIntegerForKey(a2, "k17"); a1->m_gameVersion = v63; DS_Dictionary::getIntegerForKey(a2, "k27"); a1->m_featured = v64; DS_Dictionary::getIntegerForKey(a2, "k75"); a1->m_isEpic = v65; if ( !v65 ) a1->m_isEpic = DS_Dictionary::getBoolForKey(a2, "k75"); a1->m_autoLevel = DS_Dictionary::getBoolForKey(a2, "k33"); a1->m_unlisted = DS_Dictionary::getBoolForKey(a2, "k79"); a1->m_friendsOnly = DS_Dictionary::getBoolForKey(a2, "k94"); DS_Dictionary::getIntegerForKey(a2, "k41"); v67 = v66; v68 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_password.seed = (int)v68; a1->m_password.random = (int)v68 + v67; DS_Dictionary::getIntegerForKey(a2, "k42"); v70 = v69; a1->m_originalLevel.value = v69; v71 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_originalLevel.seed = (int)v71; a1->m_originalLevel.random = (int)v71 + v70; a1->m_twoPlayerMode = DS_Dictionary::getBoolForKey(a2, "k43"); DS_Dictionary::getIntegerForKey(a2, "k45"); a1->m_songID = v72; DS_Dictionary::getIntegerForKey(a2, "k46"); a1->m_levelRev = v73; a1->m_hasBeenModified = DS_Dictionary::getBoolForKey(a2, "k47"); DS_Dictionary::getIntegerForKey(a2, "k48"); v75 = v74; a1->m_objectCount.value = v74; v76 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_objectCount.seed = (int)v76; a1->m_objectCount.random = (int)v76 + v75; v77 = DS_Dictionary::getStringForKey(a2, &Buf2, "k67"); sub_140051590((__int64)&a1->m_capacityString, v77); sub_14003A830((__int64)&Buf2); DS_Dictionary::getIntegerForKey(a2, "k66"); a1->m_starsRequested = v78; a1->m_highObjectsEnabled = DS_Dictionary::getBoolForKey(a2, "k69"); a1->m_unlimitedObjectsEnabled = DS_Dictionary::getBoolForKey(a2, "k93"); DS_Dictionary::getIntegerForKey(a2, "k80"); a1->m_workingTime = v79; DS_Dictionary::getIntegerForKey(a2, "k81"); a1->m_workingTime2 = v80; a1->m_lowDetailMode = DS_Dictionary::getBoolForKey(a2, "k72"); a1->m_lowDetailModeToggled = DS_Dictionary::getBoolForKey(a2, "k73"); a1->m_disableShakeToggled = DS_Dictionary::getBoolForKey(a2, "k112"); DS_Dictionary::getIntegerForKey(a2, "k83"); a1->m_levelIndex = v81; v82 = DS_Dictionary::getStringForKey(a2, &Buf2, "k104"); sub_140051590((__int64)&a1->m_songIDs, v82); sub_14003A830((__int64)&Buf2); v83 = DS_Dictionary::getStringForKey(a2, &Buf2, "k105"); sub_140051590((__int64)&a1->m_sfxIDs, v83); sub_14003A830((__int64)&Buf2); DS_Dictionary::getIntegerForKey(a2, "k106"); a1->m_songSize = v84; } if ( a1->m_levelType == Main ) { a1->m_isUnlocked = DS_Dictionary::getBoolForKey(a2, "k38"); DS_Dictionary::getIntegerForKey(a2, "k37"); a1->m_requiredCoins = v85; } if ( a1->m_levelType == Editor ) { FloatForKey = DS_Dictionary::getFloatForKey(a2, "kI1"); v87 = DS_Dictionary::getFloatForKey(a2, "kI2"); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v111, FloatForKey, v87); cocos2d::CCPoint::operator=(&a1->m_lastCameraPos, v88); a1->m_lastEditorZoom = DS_Dictionary::getFloatForKey(a2, "kI3"); DS_Dictionary::getIntegerForKey(a2, "kI4"); a1->m_lastBuildPage = v89; DS_Dictionary::getIntegerForKey(a2, "kI5"); a1->m_lastBuildTab = v90; DS_Dictionary::getIntegerForKey(a2, "kI7"); a1->m_lastBuildGroupID = v91; DictForKey = DS_Dictionary::getDictForKey(a2, "kI6", 0); v93 = DictForKey; if ( a1->m_lastBuildSave != DictForKey ) { if ( DictForKey ) cocos2d::CCObject::retain(DictForKey); m_lastBuildSave = a1->m_lastBuildSave; if ( m_lastBuildSave ) cocos2d::CCObject::release(m_lastBuildSave); a1->m_lastBuildSave = v93; } v95 = DS_Dictionary::getBoolForKey(a2, "k61"); a1->m_firstCoinVerified.value = v95; v96 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_firstCoinVerified.seed = (int)v96; a1->m_firstCoinVerified.random = v95 + (int)v96; v97 = DS_Dictionary::getBoolForKey(a2, "k62"); a1->m_secondCoinVerified.value = v97; v98 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_secondCoinVerified.seed = (int)v98; a1->m_secondCoinVerified.random = v97 + (int)v98; v99 = DS_Dictionary::getBoolForKey(a2, "k63"); a1->m_thirdCoinVerified.value = v99; v100 = (float)((float)rand() / 32767.0) * 1000.0; a1->m_thirdCoinVerified.seed = (int)v100; a1->m_thirdCoinVerified.random = v99 + (int)v100; v101 = DS_Dictionary::getStringForKey(a2, &Buf2, "k34"); sub_140051590((__int64)&a1->m_recordString, v101); sub_14003A830((__int64)&Buf2); } DS_Dictionary::getIntegerForKey(a2, "k50"); v103 = v102; if ( v102 < 15 ) { Buf2 = 0; *(_QWORD *)&v114 = 0; *((_QWORD *)&v114 + 1) = 15; LOBYTE(Buf2) = 0; p_m_levelString = &a1->m_levelString; if ( a1->m_levelString.m_data.m_capacity > 0xF ) p_m_levelString = (std::string *)a1->m_levelString.m_data.m_bigStorage; m_size = a1->m_levelString.m_data.m_size; v106 = m_size; if ( m_size ) v106 = 0; if ( memcmp(p_m_levelString, &Buf2, v106) || m_size ) { if ( a1->m_levelType == Editor ) { v107 = cocos2d::ZipUtils::compressString(&Buf2, &a1->m_levelString, 0, 11); sub_140051590((__int64)&a1->m_levelString, v107); sub_14003A830((__int64)&Buf2); } else { sub_14003CCE0((void **)&a1->m_levelString, byte_140518980, 0); } } } if ( v103 < 27 ) { v108 = sub_14003BDB0((__int64)v112, (__int64)&a1->m_levelDesc); v109 = v108; v111 = v108; if ( *(_QWORD *)(v108 + 16) ) { cocos2d::ZipUtils::base64URLEncode(&Buf2, v108); } else { Buf2 = 0; v114 = 0; Buf2 = *(_OWORD *)v108; v114 = *(_OWORD *)(v108 + 16); *(_QWORD *)(v108 + 16) = 0; *(_QWORD *)(v108 + 24) = 15; *(_BYTE *)v108 = 0; } sub_14003A830(v109); sub_140051590((__int64)&a1->m_levelDesc, (__int64)&Buf2); if ( *((_QWORD *)&v114 + 1) > 0xFu ) { v110 = (void *)Buf2; if ( (unsigned __int64)(*((_QWORD *)&v114 + 1) + 1LL) >= 0x1000 ) { v110 = *(void **)(Buf2 - 8); if ( (unsigned __int64)(Buf2 - (_QWORD)v110 - 8) > 0x1F ) invalid_parameter_noinfo_noreturn(); } j_j_free(v110); } } }
GD Web Decomp Icon

GD Web Decomp

Raw Source