// // GameLevelManager::getOnlineLevels from 0x10053fa90 to 0x10054062f (2975 bytes) // // 1 xrefs: // > LevelBrowserLayer::loadPage @ 0x10048ef99 // // 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 // void __fastcall GameLevelManager::getOnlineLevels(GameLevelManager *a1, GJSearchObject *a2) { __m128 v2; // xmm0 char *Key; // r14 bool m_completedFilter; // al GameLevelManager *v5; // rbx char *v6; // r14 GameManager *v7; // rax bool GameVariable; // al cocos2d::CCArray *CompletedLevels; // r13 cocos2d::CCString *v10; // rax const char *CString; // rax unsigned int i; // r12d cocos2d::CCString *v13; // rax const char *v14; // rax int v15; // eax unsigned __int8 v16; // r15 SearchType m_searchType; // eax const char *v18; // rdi int v19; // ebx GameManager *v20; // rax const char *longStorage; // rbx size_t v22; // rax std::string::size_type v23; // r14 unsigned __int8 v24; // r13 char *v25; // r15 size_t v26; // r12 std::string *p_m_searchQuery; // r14 GJSearchObject *v28; // rax GJSearchObject *v29; // rax std::string *p_m_difficulty; // rax std::string *p_m_length; // rax cocos2d::CCString *v32; // rax const char *v33; // rsi cocos2d::CCString *v34; // rax const std::string::value_type *elems; // rsi int v36; // ebx std::string::pointer v37; // r14 cocos2d::CCString *v38; // rax const char *v39; // rax const char *v40; // rbx size_t v41; // rax size_t v42; // r14 char *v43; // r15 size_t v44; // r12 size_t v45; // rax size_t v46; // rbx char *v47; // r14 char *v48; // rsi size_t v49; // r15 char v50; // [rsp+0h] [rbp-170h] char v51; // [rsp+0h] [rbp-170h] char v52; // [rsp+0h] [rbp-170h] std::string v53; // [rsp+40h] [rbp-130h] BYREF GameLevelManager *v54; // [rsp+58h] [rbp-118h] _QWORD v55[2]; // [rsp+60h] [rbp-110h] BYREF void *v56; // [rsp+70h] [rbp-100h] _QWORD v57[2]; // [rsp+78h] [rbp-F8h] BYREF void *v58; // [rsp+88h] [rbp-E8h] __m128 v59; // [rsp+90h] [rbp-E0h] BYREF void *v60; // [rsp+A0h] [rbp-D0h] __m128 v61; // [rsp+B0h] [rbp-C0h] BYREF void *v62; // [rsp+C0h] [rbp-B0h] int m_songID; // [rsp+CCh] [rbp-A4h] char *v64; // [rsp+D0h] [rbp-A0h] std::string::value_type *data; // [rsp+D8h] [rbp-98h] std::string v66; // [rsp+E0h] [rbp-90h] BYREF int v67; // [rsp+FCh] [rbp-74h] std::string v68; // [rsp+100h] [rbp-70h] BYREF int v69; // [rsp+11Ch] [rbp-54h] std::string __dst; // [rsp+120h] [rbp-50h] BYREF GJSearchObject *v71; // [rsp+138h] [rbp-38h] bool m_songFilter; // [rsp+146h] [rbp-2Ah] bool m_customSongFilter; // [rsp+147h] [rbp-29h] Key = (char *)GJSearchObject::getKey(a2); if ( GameLevelManager::isDLActive(a1, Key) ) return; v54 = a1; v64 = Key; GameLevelManager::addDLToActive(a1, Key); LOBYTE(v69) = a2->m_uncompletedFilter; v71 = a2; if ( (_BYTE)v69 == 1 ) { *(_WORD *)&v66.__r_.__value_.__l.0 = 10242; data = v66.__r_.__value_.__s.__data_; v66.__r_.__value_.__s.__data_[1] = 0; } else { m_completedFilter = a2->m_completedFilter; *(_WORD *)&v66.__r_.__value_.__l.0 = 10242; data = v66.__r_.__value_.__s.__data_; v66.__r_.__value_.__s.__data_[1] = 0; if ( !m_completedFilter ) { v16 = 0; v69 = 0; goto LABEL_13; } } v5 = (GameLevelManager *)qword_1009A28E0; if ( !qword_1009A28E0 ) { v6 = (char *)operator new(0x3C8u); cocos2d::CCNode::CCNode((__int64)v6); *(_QWORD *)v6 = off_100960890; v2 = 0; *(_OWORD *)(v6 + 328) = 0; *((_QWORD *)v6 + 40) = v6 + 328; *((_QWORD *)v6 + 62) = 0; *((_OWORD *)v6 + 32) = 0; *(_OWORD *)(v6 + 344) = 0; *(_OWORD *)(v6 + 360) = 0; *(_OWORD *)(v6 + 376) = 0; *(_OWORD *)(v6 + 392) = 0; *(_OWORD *)(v6 + 408) = 0; *(_OWORD *)(v6 + 424) = 0; *(_OWORD *)(v6 + 440) = 0; *(_OWORD *)(v6 + 456) = 0; *(_OWORD *)(v6 + 472) = 0; *((_DWORD *)v6 + 122) = 0; *((_QWORD *)v6 + 63) = v6 + 512; *((_OWORD *)v6 + 33) = 0; *((_OWORD *)v6 + 34) = 0; *((_OWORD *)v6 + 35) = 0; *((_OWORD *)v6 + 36) = 0; *(_OWORD *)(v6 + 696) = 0; *(_OWORD *)(v6 + 680) = 0; *(_OWORD *)(v6 + 664) = 0; *(_OWORD *)(v6 + 648) = 0; *(_OWORD *)(v6 + 632) = 0; *(_OWORD *)(v6 + 616) = 0; *(_OWORD *)(v6 + 600) = 0; v6[712] = 0; *((_OWORD *)v6 + 48) = 0; *((_OWORD *)v6 + 47) = 0; *((_OWORD *)v6 + 46) = 0; *((_OWORD *)v6 + 45) = 0; *(_OWORD *)(v6 + 945) = 0; *(_OWORD *)(v6 + 936) = 0; *(_OWORD *)(v6 + 920) = 0; *(_OWORD *)(v6 + 904) = 0; *(_OWORD *)(v6 + 888) = 0; *(_OWORD *)(v6 + 872) = 0; *(_OWORD *)(v6 + 856) = 0; *(_OWORD *)(v6 + 840) = 0; *(_OWORD *)(v6 + 824) = 0; *(_OWORD *)(v6 + 808) = 0; *(_OWORD *)(v6 + 792) = 0; qword_1009A28E0 = (__int64)v6; GameLevelManager::init((GameLevelManager *)v6); v5 = (GameLevelManager *)qword_1009A28E0; } v7 = GameManager::sharedState(); GameVariable = GameManager::getGameVariable(v7, "0073"); CompletedLevels = GameLevelManager::getCompletedLevels(v5, GameVariable); if ( (unsigned int)sub_100720070(CompletedLevels) ) { sub_1007200C0(CompletedLevels, 0); v10 = (cocos2d::CCString *)sub_1007AB580("%i", v50); CString = cocos2d::CCString::getCString(v10); std::string::append(&v66, CString); for ( i = 1; i < (unsigned int)sub_100720070(CompletedLevels); ++i ) { sub_1007200C0(CompletedLevels, i); std::string::append(&v66, ","); v13 = (cocos2d::CCString *)sub_1007AB580("%i", v51); v14 = cocos2d::CCString::getCString(v13); std::string::append(&v66, v14); } } std::string::append(&v66, ")"); v15 = sub_100720070(CompletedLevels); LOBYTE(v15) = v15 != 0; v16 = v15 & (v69 ^ 1); LOBYTE(v15) = v69 & v15; v69 = v15; LABEL_13: m_searchType = v71->m_searchType; m_songID = v71->m_songID; m_songFilter = v71->m_songFilter; m_customSongFilter = v71->m_customSongFilter; if ( m_searchType != UsersLevels ) { v67 = 0; if ( m_searchType ) goto LABEL_43; LABEL_25: if ( (v71->m_searchQuery.m_data.m_short.sizex2 & 1) != 0 ) { sub_100006B70( &v68, v71->m_searchQuery.m_data.m_long.longStorage, v71->m_searchQuery.m_data.m_long.size, *(double *)v2.i64); } else { v68.m_data.m_long.longStorage = v71->m_searchQuery.m_data.m_long.longStorage; v2 = *(__m128 *)&v71->m_searchQuery.m_data.m_short.sizex2; *(__m128 *)&v68.m_data.m_short.sizex2 = v2; } if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) longStorage = v68.m_data.m_long.longStorage; else longStorage = v68.m_data.m_short.shortStorage.__elems_; v22 = strlen(longStorage); if ( v22 >= 0xFFFFFFFFFFFFFFF8LL ) sub_100006BF0(*(double *)v2.i64); v23 = v22; v24 = v16; if ( v22 >= 0x17 ) { v26 = 26; if ( (v22 | 7) != 0x17 ) v26 = (v22 | 7) + 1; v25 = (char *)operator new(v26); __dst.__r_.__value_.__r.__words[2] = (std::string::size_type)v25; __dst.__r_.__value_.__r.__words[0] = v26 | 1; __dst.__r_.__value_.__l.__size_ = v23; } else { __dst.__r_.__value_.__s.0 = (std::string::__short::$7162EEB0FEF29CC674EFA33D0008C7E0)(2 * v22); v25 = __dst.__r_.__value_.__s.__data_; if ( !v22 ) goto LABEL_39; } memmove(v25, longStorage, v23); LABEL_39: v25[v23] = 0; if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) operator delete(v68.m_data.m_long.longStorage); v16 = v24; if ( (*(_BYTE *)&__dst.__r_.__value_.__s.0 & 1) != 0 ) operator delete(__dst.__r_.__value_.__l.__data_); goto LABEL_43; } if ( (v71->m_searchQuery.m_data.m_short.sizex2 & 1) != 0 ) { sub_100006B70( &__dst, v71->m_searchQuery.m_data.m_long.longStorage, v71->m_searchQuery.m_data.m_long.size, *(double *)v2.i64); } else { __dst.__r_.__value_.__r.__words[2] = (std::string::size_type)v71->m_searchQuery.m_data.m_long.longStorage; v2 = *(__m128 *)&v71->m_searchQuery.m_data.m_short.sizex2; *(__m128 *)&__dst.__r_.__value_.__l.0 = v2; } if ( (*(_BYTE *)&__dst.__r_.__value_.__s.0 & 1) != 0 ) v18 = __dst.__r_.__value_.__l.__data_; else v18 = __dst.__r_.__value_.__s.__data_; v19 = atoi(v18); v20 = GameManager::sharedState(); LOBYTE(v20) = v19 == v20->m_playerUserID.random - v20->m_playerUserID.seed; v67 = (int)v20; if ( (*(_BYTE *)&__dst.__r_.__value_.__s.0 & 1) != 0 ) operator delete(__dst.__r_.__value_.__l.__data_); if ( !v71->m_searchType ) goto LABEL_25; LABEL_43: GameLevelManager::getBasePostString(&__dst, v2); p_m_searchQuery = &v71->m_searchQuery; if ( (v71->m_searchQuery.m_data.m_short.sizex2 & 1) != 0 ) { sub_100006B70( &v68, v71->m_searchQuery.m_data.m_long.longStorage, v71->m_searchQuery.m_data.m_long.size, *(double *)v2.i64); } else { v68.m_data.m_long.longStorage = v71->m_searchQuery.m_data.m_long.longStorage; v2 = *(__m128 *)&p_m_searchQuery->m_data.m_short.sizex2; *(_OWORD *)&v68.m_data.m_short.sizex2 = *(_OWORD *)&p_m_searchQuery->m_data.m_short.sizex2; } if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) { v28 = v71; if ( (v71->m_difficulty.m_data.m_short.sizex2 & 1) != 0 ) goto LABEL_48; } else { v28 = v71; if ( (v71->m_difficulty.m_data.m_short.sizex2 & 1) != 0 ) { LABEL_48: sub_100006B70( &v59, v28->m_difficulty.m_data.m_long.longStorage, v28->m_difficulty.m_data.m_long.size, *(double *)v2.i64); if ( (v59.i8[0] & 1) != 0 ) goto LABEL_49; LABEL_53: v29 = v71; if ( (v71->m_length.m_data.m_short.sizex2 & 1) != 0 ) goto LABEL_50; goto LABEL_54; } } p_m_difficulty = &v28->m_difficulty; v60 = p_m_difficulty->m_data.m_long.longStorage; v2 = *(__m128 *)&p_m_difficulty->m_data.m_short.sizex2; v59 = *(__m128 *)&p_m_difficulty->m_data.m_short.sizex2; if ( (v59.i8[0] & 1) == 0 ) goto LABEL_53; LABEL_49: v29 = v71; if ( (v71->m_length.m_data.m_short.sizex2 & 1) != 0 ) { LABEL_50: sub_100006B70(&v61, v29->m_length.m_data.m_long.longStorage, v29->m_length.m_data.m_long.size, *(double *)v2.i64); goto LABEL_55; } LABEL_54: p_m_length = &v29->m_length; v62 = p_m_length->m_data.m_long.longStorage; v2 = *(__m128 *)&p_m_length->m_data.m_short.sizex2; v61 = *(__m128 *)&p_m_length->m_data.m_short.sizex2; LABEL_55: v32 = (cocos2d::CCString *)sub_1007AB580( "&type=%i&str=%s&diff=%s&len=%s&page=%i&total=%i&uncompleted=%i&onlyCompleted=%i&featured=" "%i&original=%i&twoPlayer=%i&coins=%i", v71->m_total); v33 = cocos2d::CCString::getCString(v32); std::string::append(&__dst, v33); if ( (v61.i8[0] & 1) != 0 ) { operator delete(v62); if ( (v59.i8[0] & 1) == 0 ) { LABEL_57: if ( (v68.m_data.m_short.sizex2 & 1) == 0 ) goto LABEL_58; LABEL_62: operator delete(v68.m_data.m_long.longStorage); if ( !v71->m_epicFilter ) goto LABEL_64; goto LABEL_63; } } else if ( (v59.i8[0] & 1) == 0 ) { goto LABEL_57; } operator delete(v60); if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) goto LABEL_62; LABEL_58: if ( v71->m_epicFilter ) { LABEL_63: v33 = "&epic=1"; std::string::append(&__dst, "&epic=1"); } LABEL_64: if ( v71->m_legendaryFilter ) { v33 = "&legendary=1"; std::string::append(&__dst, "&legendary=1"); } if ( v71->m_mythicFilter ) { v33 = "&mythic=1"; std::string::append(&__dst, "&mythic=1"); } if ( (_BYTE)v67 ) { v33 = "&local=1"; std::string::append(&__dst, "&local=1"); } if ( m_songFilter ) { std::string::append(&__dst, "&song="); v34 = (cocos2d::CCString *)sub_1007AB580("%i", v52); v33 = cocos2d::CCString::getCString(v34); std::string::append(&__dst, v33); if ( m_customSongFilter ) { v33 = "&customSong=1"; std::string::append(&__dst, "&customSong=1"); } } GameLevelManager::writeSpecialFilters((std::string *)&v68, v2, (__int64)v33, (__int64)v71); if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) elems = v68.m_data.m_long.longStorage; else elems = v68.m_data.m_short.shortStorage.__elems_; std::string::append(&__dst, elems); if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) operator delete(v68.m_data.m_long.longStorage); if ( ((v16 | (unsigned __int8)v69) & 1) != 0 ) { std::string::append(&__dst, "&completedLevels="); if ( (*(_BYTE *)&v66.__r_.__value_.__s.0 & 1) != 0 ) data = v66.__r_.__value_.__l.__data_; std::string::append(&__dst, data); } if ( v71->m_searchType == LevelListsOnClick ) { if ( (p_m_searchQuery->m_data.m_short.sizex2 & 1) != 0 ) sub_100006B70( &v68, v71->m_searchQuery.m_data.m_long.longStorage, v71->m_searchQuery.m_data.m_long.size, *(double *)v2.i64); else v68 = *p_m_searchQuery; if ( (v68.m_data.m_short.sizex2 & 1) != 0 ) { v37 = v68.m_data.m_long.longStorage; v36 = atoi(v68.m_data.m_long.longStorage); operator delete(v37); } else { v36 = atoi(v68.m_data.m_short.shortStorage.__elems_); } if ( !GameLevelManager::hasDownloadedLevel(v54, -v36) ) std::string::append(&__dst, "&inc=1"); } std::string::append(&__dst, "&secret="); v38 = (cocos2d::CCString *)sub_1007AB580("%c%s%s%c%c%s", (char)"7"); v39 = cocos2d::CCString::getCString(v38); std::string::append(&__dst, v39); v53.__r_.__value_.__r.__words[2] = (std::string::size_type)operator new(0x38u); v53.__r_.__value_.__r.__words[0] = 57; v53.__r_.__value_.__l.__size_ = 52; strcpy(v53.__r_.__value_.__l.__data_, "https://www.boomlings.com/database/getGJLevels21.php"); if ( (*(_BYTE *)&__dst.__r_.__value_.__s.0 & 1) != 0 ) v40 = __dst.__r_.__value_.__l.__data_; else v40 = __dst.__r_.__value_.__s.__data_; v41 = strlen(v40); if ( v41 >= 0xFFFFFFFFFFFFFFF8LL ) sub_100006BF0(2.057594829120962e-81); v42 = v41; if ( v41 >= 0x17 ) { v44 = 26; if ( (v41 | 7) != 0x17 ) v44 = (v41 | 7) + 1; v43 = (char *)operator new(v44); v56 = v43; v55[0] = v44 | 1; v55[1] = v42; goto LABEL_101; } LOBYTE(v55[0]) = 2 * v41; v43 = (char *)v55 + 1; if ( v41 ) LABEL_101: memmove(v43, v40, v42); v43[v42] = 0; v45 = strlen(v64); if ( v45 >= 0xFFFFFFFFFFFFFFF8LL ) sub_100006BF0(2.057594829120962e-81); v46 = v45; if ( v45 >= 0x17 ) { v49 = 26; if ( (v45 | 7) != 0x17 ) v49 = (v45 | 7) + 1; v47 = (char *)operator new(v49); v58 = v47; v57[0] = v49 | 1; v57[1] = v46; v48 = v64; goto LABEL_109; } LOBYTE(v57[0]) = 2 * v45; v47 = (char *)v57 + 1; v48 = v64; if ( v45 ) LABEL_109: memmove(v47, v48, v46); v47[v46] = 0; GameLevelManager::ProcessHttpRequest(v54, &v53, (__int64)v55, (__int64)v57, 2); if ( (v57[0] & 1) != 0 ) { operator delete(v58); if ( (v55[0] & 1) == 0 ) { LABEL_112: if ( (*(_BYTE *)&v53.__r_.__value_.__s.0 & 1) == 0 ) goto LABEL_113; LABEL_119: operator delete(v53.__r_.__value_.__l.__data_); if ( (*(_BYTE *)&__dst.__r_.__value_.__s.0 & 1) == 0 ) { LABEL_114: if ( (*(_BYTE *)&v66.__r_.__value_.__s.0 & 1) == 0 ) return; goto LABEL_115; } goto LABEL_120; } } else if ( (v55[0] & 1) == 0 ) { goto LABEL_112; } operator delete(v56); if ( (*(_BYTE *)&v53.__r_.__value_.__s.0 & 1) != 0 ) goto LABEL_119; LABEL_113: if ( (*(_BYTE *)&__dst.__r_.__value_.__s.0 & 1) == 0 ) goto LABEL_114; LABEL_120: operator delete(__dst.__r_.__value_.__l.__data_); if ( (*(_BYTE *)&v66.__r_.__value_.__s.0 & 1) != 0 ) LABEL_115: operator delete(v66.__r_.__value_.__l.__data_); }
GD Web Decomp Icon

GD Web Decomp

Raw Source