// // EditorSoundConfigUploadPopup::performUpload from 0x788f4c to 0x7891f0 (676 bytes) // // 2 xrefs: // > EditorSoundConfigUploadPopup::onUpload @ 0x789224 // > EditorSoundConfigUploadPopup::onUploadAsUpdate @ 0x789230 // // This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False! // // 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 11:59:35 +0000 // GJAccountManager *__fastcall EditorSoundConfigUploadPopup::performUpload(GJAccountManager *this, char *a2) { GJAccountManager *v2; // r4 GJAccountManager *v4; // r0 GJAccountManager *v5; // r0 int v6; // r0 int v7; // r2 char *v8; // r7 int v9; // r3 int *v10; // r0 int *v11; // r0 int v12; // r2 int v13; // r3 int *v14; // r0 int *v15; // r0 int v16; // r3 int v17; // r11 int v18; // r10 int *v19; // r8 int *v20; // r0 int v21; // r3 int v22; // r0 int v23; // r0 int v24; // r0 LoadingCircle *v25; // r0 cocos2d::CCLayerColor *v26; // r0 int v27; // r3 GameLevelManager *v28; // r0 GameLevelManager *v29; // r0 int v30; // r3 GameManager *v31; // [sp+1Ch] [bp-68h] int v32; // [sp+20h] [bp-64h] int v33; // [sp+28h] [bp-5Ch] BYREF int v34; // [sp+2Ch] [bp-58h] char *v35; // [sp+30h] [bp-54h] int v36[3]; // [sp+34h] [bp-50h] BYREF int v37[3]; // [sp+40h] [bp-44h] BYREF int v38[3]; // [sp+4Ch] [bp-38h] BYREF int v39[3]; // [sp+58h] [bp-2Ch] BYREF int v40[3]; // [sp+64h] [bp-20h] BYREF int v41[5]; // [sp+70h] [bp-14h] BYREF v2 = this; if ( !*((_BYTE *)this + 732) ) { v4 = (GJAccountManager *)GJAccountManager::sharedState(this); if ( *((_DWORD *)v4 + 70) - *((_DWORD *)v4 + 71) > 0 ) { std::string::basic_string(&v33, *((_DWORD *)v2 + 184) + 324); std::string::basic_string(v36, *((_DWORD *)v2 + 184) + 336); while ( 1 ) { v6 = v33 & 1; if ( v6 ) { v7 = v34; if ( !v34 ) goto LABEL_12; v8 = v35; } else { v7 = (int)(unsigned __int8)v33 >> 1; if ( !v7 ) goto LABEL_13; v8 = (char *)&v33 + 1; } if ( v8[v7 - 1] != 32 ) break; if ( v6 ) { v35[--v34] = 0; } else { v30 = ((int)(unsigned __int8)v33 >> 1) - 1; LOBYTE(v33) = 2 * v30; *((_BYTE *)&v41[-17] + v30 - 3) = 0; } } if ( v6 ) { LABEL_12: v9 = v34; goto LABEL_14; } LABEL_13: v9 = (int)(unsigned __int8)v33 >> 1; LABEL_14: if ( v9 ) { std::string::basic_string(v38, *((_DWORD *)v2 + 184) + 372); v12 = LOBYTE(v38[0]) << 31; if ( (v38[0] & 1) != 0 ) v13 = v38[1]; else v13 = (int)LOBYTE(v38[0]) >> 1; if ( v13 ) { v16 = *((_DWORD *)v2 + 184); v17 = *(_DWORD *)(v16 + 300); v18 = *(_DWORD *)(v16 + 304); if ( v17 > 0 && v18 > 0 ) { v21 = *((unsigned __int8 *)v2 + 756); if ( *((_BYTE *)v2 + 756) ) { if ( *((_BYTE *)v2 + 757) ) v21 = 3; else v21 = 4; } v22 = *((_DWORD *)v2 + 180); *((_DWORD *)v2 + 190) = v21; *((_DWORD *)v2 + 192) = a2; *((_BYTE *)v2 + 732) = 1; if ( v22 ) (*(void (__fastcall **)(int, _DWORD, int))(*(_DWORD *)v22 + 172))(v22, 0, v12); v23 = *((_DWORD *)v2 + 181); if ( v23 ) (*(void (__fastcall **)(int, _DWORD, int))(*(_DWORD *)v23 + 172))(v23, 0, v12); v24 = *((_DWORD *)v2 + 182); if ( v24 ) (*(void (__fastcall **)(int, _DWORD, int))(*(_DWORD *)v24 + 172))(v24, 0, v12); v25 = *((LoadingCircle **)v2 + 191); if ( v25 ) v25 = (LoadingCircle *)(*(int (__fastcall **)(LoadingCircle *, _DWORD, int))(*(_DWORD *)v25 + 172))( v25, 0, v12); v26 = LoadingCircle::create(v25); v27 = *((_DWORD *)v2 + 115); *((_DWORD *)v2 + 179) = v26; *((_DWORD *)v26 + 111) = v27; v28 = (GameLevelManager *)LoadingCircle::show(*((cocos2d::CCNode ***)v2 + 179)); v29 = (GameLevelManager *)GameLevelManager::sharedState(v28); *((_DWORD *)v29 + 217) = (char *)v2 + 712; v19 = v41; v31 = (GameManager *)GameLevelManager::sharedState(v29); v32 = *((_DWORD *)v2 + 190); std::string::basic_string(v41, *((_DWORD *)v2 + 184) + 348); GameLevelManager::uploadEditorSoundConfig(v31, (int)&v33, (int)v36, (int)v38, v17, v18, a2, v32, (int)v41); } else { v19 = v40; memset(v40, 0, sizeof(v40)); std::string::__init(v40, "This sound pack is empty. Add at least one sound before uploading.", 0x42u); v20 = FLAlertLayer::create(0, (cocos2d::CCLabelBMFont *)"Error", (int)v40, (ButtonSprite *)"OK", nullptr); (*(void (__fastcall **)(int *))(*v20 + 656))(v20); } v15 = v19; } else { memset(v39, 0, sizeof(v39)); std::string::__init(v39, "This sound pack has no data.", 0x1Cu); v14 = FLAlertLayer::create(0, (cocos2d::CCLabelBMFont *)"Error", (int)v39, (ButtonSprite *)"OK", nullptr); (*(void (__fastcall **)(int *))(*v14 + 656))(v14); v15 = v39; } std::string::~string((int)v15); v11 = v38; } else { memset(v37, 0, sizeof(v37)); std::string::__init(v37, "This sound pack has no name. Set one before uploading.", 0x36u); v10 = FLAlertLayer::create(0, (cocos2d::CCLabelBMFont *)"Error", (int)v37, (ButtonSprite *)"OK", nullptr); (*(void (__fastcall **)(int *))(*v10 + 656))(v10); v11 = v37; } std::string::~string((int)v11); std::string::~string((int)v36); return (GJAccountManager *)std::string::~string((int)&v33); } else { v5 = (GJAccountManager *)GJAccountManager::sharedState(v4); return (GJAccountManager *)GJAccountManager::showAccountNeededAlert(v5, "upload sound packs"); } } return this; }
GD Web Decomp Icon

GD Web Decomp

Raw Source