// // LevelTools::createStarPackDict from 0x72f584 to 0x72f96c (1000 bytes) // // 2 xrefs: // > GameManager::recountUserStats @ 0x726bc8 // > @ 0xf91d8 // // 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 12:52:35 +0000 // cocos2d::CCDictionary *__fastcall LevelTools::createStarPackDict(LevelTools *this) { cocos2d::CCDictionary *v1; // x26 cocos2d::CCArray *v2; // x0 __int64 v3; // x0 unsigned __int8 v4; // w2 cocos2d::CCArray *v5; // x24 unsigned __int64 v6; // x25 _BYTE *v7; // x19 __int64 v8; // x22 unsigned __int64 v9; // x19 size_t v10; // x3 unsigned __int64 v11; // x2 char *i; // x1 size_t v13; // x2 char *v14; // x1 int v15; // w1 const char *v16; // x1 size_t v17; // x0 cocos2d::CCObject *v18; // x0 char *v19; // x2 unsigned __int64 v20; // x0 char *v21; // x3 char *v22; // x0 unsigned int v23; // w19 unsigned int v24; // w1 cocos2d::CCString *v25; // x0 int v26; // w21 cocos2d::CCObject *v27; // x0 unsigned int v28; // w20 __int64 *v30; // x20 _BYTE *v31; // x22 std::logic_error *exception; // x20 char *v33; // [xsp+68h] [xbp+68h] __int64 v34; // [xsp+70h] [xbp+70h] BYREF unsigned __int64 v35; // [xsp+78h] [xbp+78h] void *v36; // [xsp+80h] [xbp+80h] __int64 v37; // [xsp+88h] [xbp+88h] BYREF __int64 v38; // [xsp+90h] [xbp+90h] void *v39; // [xsp+98h] [xbp+98h] __int64 v40[2]; // [xsp+A0h] [xbp+A0h] BYREF void *v41; // [xsp+B0h] [xbp+B0h] v1 = (cocos2d::CCDictionary *)cocos2d::CCDictionary::create(_stack_chk_guard); v34 = 0; v35 = 0; v36 = nullptr; v2 = (cocos2d::CCArray *)std::string::__init( &v34, "1,3,2,4,3,4,5,5,6,6,7,6,8,7,9,8,10,8,11,9,19,10,20,10,21,10,22,10,26,10,27,10,28,10,29,10,3" "0,10,31,10,32,4,33,5,34,6,35,8,36,8,37,5,38,5,39,6,40,7,41,8,42,8,43,8,44,9,45,6,46,10,47,1" "0,48,10,49,10,50,10,52,4,53,3,54,4,55,4,56,5,57,6,58,7,59,8,60,8,61,8,62,9,63,9,64,10,65,10,66,10", 0x117u); v3 = cocos2d::CCArray::create(v2); v4 = v34; v5 = (cocos2d::CCArray *)v3; if ( (v34 & 1) == 0 ) { LODWORD(v6) = (int)(unsigned __int8)v34 >> 1; if ( !(_DWORD)v6 ) goto LABEL_3; v7 = (char *)&v34 + 1; v8 = -1; v30 = (__int64 *)((char *)&v34 + (int)v6 + 1); if ( v30 == (__int64 *)((char *)&v34 + 1) ) { LABEL_57: v6 = (int)v6; goto LABEL_5; } LABEL_50: v31 = v7; if ( *v7 == 44 ) { v8 = 0; } else { do { if ( v30 == (__int64 *)++v31 ) { v8 = -1; goto LABEL_60; } } while ( *v31 != 44 ); v8 = v31 - v7; } LABEL_60: LODWORD(v6) = (int)(unsigned __int8)v34 >> 1; if ( (v34 & 1) != 0 ) { v6 = v35; goto LABEL_5; } goto LABEL_57; } v6 = v35; v7 = v36; if ( v35 ) { v30 = (__int64 *)((char *)v36 + v35); if ( v36 == (char *)v36 + v35 ) goto LABEL_4; goto LABEL_50; } LABEL_3: v6 = 0; LABEL_4: v8 = -1; LABEL_5: v37 = 0; v38 = 0; v9 = 0; v39 = nullptr; v10 = v8; if ( (v34 & 1) == 0 ) goto LABEL_24; LABEL_6: v11 = v35; if ( v9 > v35 ) { LABEL_58: exception = (std::logic_error *)_cxa_allocate_exception(0x10u); std::logic_error::logic_error(exception, "basic_string"); *(_QWORD *)exception = off_1536D68; _cxa_throw( exception, (struct type_info *)&`typeinfo for'std::out_of_range, (void (*)(void *))std::logic_error::~logic_error); } for ( i = (char *)v36; ; i = (char *)&v34 + 1 ) { v13 = v11 - v9; v14 = &i[v9]; if ( v13 > v10 ) v13 = v10; std::string::__init(&v37, v14, v13); v15 = v37 & 1; if ( v15 ) { if ( v9 == v6 ) { v15 = 1; if ( !v38 ) goto LABEL_17; } v16 = (const char *)v39; } else { if ( v9 == v6 && !((int)(unsigned __int8)v37 >> 1) ) goto LABEL_17; v16 = (char *)&v37 + 1; } v33 = (char *)v16; v40[0] = 0; v40[1] = 0; v41 = nullptr; v17 = strlen(v16); std::string::__init(v40, v33, v17); v18 = (cocos2d::CCObject *)cocos2d::CCString::create(v40); cocos2d::CCArray::addObject(v5, v18); if ( (v40[0] & 1) != 0 ) operator delete(v41); v15 = v37 & 1; LABEL_17: if ( v8 == -1 ) break; v9 = v8 + 1; if ( (v34 & 1) != 0 ) { v19 = (char *)v36; v20 = v35; } else { v20 = (unsigned __int8)v34 >> 1; v19 = (char *)&v34 + 1; } v8 = -1; if ( v9 >= v20 || (v21 = &v19[v9], v22 = &v19[v20], &v19[v9] == v22) ) { if ( !v15 ) goto LABEL_22; } else if ( v19[v9] == 44 ) { LABEL_38: v8 = v21 - v19; if ( !v15 ) goto LABEL_22; } else { while ( v22 != ++v21 ) { if ( *v21 == 44 ) goto LABEL_38; } v8 = -1; if ( !v15 ) { LABEL_22: v4 = v34; goto LABEL_23; } } operator delete(v39); v4 = v34; LABEL_23: v37 = 0; v10 = v8 - v9; v38 = 0; v39 = nullptr; if ( (v4 & 1) != 0 ) goto LABEL_6; LABEL_24: v11 = v4 >> 1; if ( v9 > v11 ) goto LABEL_58; } if ( v15 ) operator delete(v39); if ( (v34 & 1) != 0 ) operator delete(v36); v23 = 0; while ( 1 ) { v28 = v23 + 1; if ( (unsigned int)cocos2d::CCArray::count(v5) <= v23 + 1 ) break; v24 = v23; v23 += 2; v25 = (cocos2d::CCString *)cocos2d::CCArray::stringAtIndex(v5, v24); v26 = cocos2d::CCString::intValue(v25); v27 = (cocos2d::CCObject *)cocos2d::CCArray::stringAtIndex(v5, v28); cocos2d::CCDictionary::setObject(v1, v27, v26); } return v1; }
GD Web Decomp Icon

GD Web Decomp

Raw Source