// // MusicDownloadManager::downloadCustomSong from 0x10064f120 to 0x10064f3ae (654 bytes) // // 1 xrefs: // > MusicDownloadManager::downloadSong @ 0x10064ed53 // // This function is hookable on this platform (idp: pc, 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:34:48 +0000 // void __fastcall MusicDownloadManager::downloadCustomSong(__int64 a1, unsigned int a2) { unsigned int v3; // eax __int64 v4; // rax const char *CString; // r14 unsigned int v6; // r12d __int64 v7; // rdi const std::string::value_type *v8; // rsi std::string::size_type v9; // rdx char v10; // r12 char *Request; // r15 char v12; // [rsp+0h] [rbp-D0h] __int128 v13; // [rsp+8h] [rbp-C8h] BYREF void *v14; // [rsp+18h] [rbp-B8h] __int128 v15; // [rsp+20h] [rbp-B0h] BYREF void *__p; // [rsp+30h] [rbp-A0h] __int128 v17; // [rsp+40h] [rbp-90h] BYREF void *v18; // [rsp+50h] [rbp-80h] __int128 v19; // [rsp+60h] [rbp-70h] BYREF void *v20; // [rsp+70h] [rbp-60h] std::string::value_type __s[16]; // [rsp+80h] [rbp-50h] BYREF void *v22; // [rsp+90h] [rbp-40h] std::string v23; // [rsp+98h] [rbp-38h] BYREF v3 = *(unsigned __int8 *)(a1 + 368); if ( (v3 & 1) != 0 ) { if ( !*(_QWORD *)(a1 + 376) ) return; } else if ( !(v3 >> 1) ) { return; } v4 = sub_10088E820("d_%i", v12); CString = (const char *)cocos2d::CCString::getCString(v4); if ( !MusicDownloadManager::getDLObject(a1, CString) ) { if ( (unsigned int)sub_1007FEF90(*(_QWORD *)(a1 + 336)) ) { v6 = 0; do { v7 = *(_QWORD *)(sub_1007FEFE0(*(_QWORD *)(a1 + 336), v6) + 320); if ( v7 ) (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v7 + 16LL))(v7, a2); ++v6; } while ( v6 < (unsigned int)sub_1007FEF90(*(_QWORD *)(a1 + 336)) ); } GameToolbox::intToString((size_t *)__s, a2); v23.__r_.__value_.__s.0 = (std::string::__short::$7162EEB0FEF29CC674EFA33D0008C7E0)14; strcpy(v23.__r_.__value_.__s.__data_, "/music/"); if ( (__s[0] & 1) != 0 ) { v8 = (const std::string::value_type *)v22; v9 = *(_QWORD *)&__s[8]; } else { v9 = (unsigned __int8)__s[0] >> 1; v8 = &__s[1]; } std::string::append(&v23, v8, v9); std::string::append(&v23, ".ogg"); if ( (*(_BYTE *)&v23.__r_.__value_.__s.0 & 1) != 0 ) { sub_10001AD30(&v15, v23.__r_.__value_.__l.__data_, v23.__r_.__value_.__l.__size_); } else { __p = v23.__r_.__value_.__l.__data_; v15 = *(_OWORD *)&v23.__r_.__value_.__l.0; } MusicDownloadManager::generateCustomContentURL(&v13, a1, &v15); if ( (v15 & 1) != 0 ) operator delete(__p); v10 = v13; if ( (v13 & 1) != 0 ) { sub_10001AD30(&v17, v14, *((unsigned __int64 *)&v13 + 1)); } else { v18 = v14; v17 = v13; } if ( (__s[0] & 1) != 0 ) { sub_10001AD30(&v19, v22, *(unsigned __int64 *)&__s[8]); } else { v20 = v22; v19 = *(_OWORD *)__s; } Request = MusicDownloadManager::ProcessHttpGetRequest( a1, (__int64)&v17, (__int64)&v19, (__int64)MusicDownloadManager::onDownloadSongCompleted, 0, 0, 0); if ( (v19 & 1) != 0 ) operator delete(v20); if ( (v17 & 1) != 0 ) operator delete(v18); MusicDownloadManager::addDLToActive(a1, CString, Request); if ( (v10 & 1) != 0 ) { operator delete(v14); if ( (*(_BYTE *)&v23.__r_.__value_.__s.0 & 1) == 0 ) { LABEL_31: if ( (__s[0] & 1) == 0 ) return; goto LABEL_32; } } else if ( (*(_BYTE *)&v23.__r_.__value_.__s.0 & 1) == 0 ) { goto LABEL_31; } operator delete(v23.__r_.__value_.__l.__data_); if ( (__s[0] & 1) == 0 ) return; LABEL_32: operator delete(v22); } }
GD Web Decomp Icon

GD Web Decomp

Raw Source