// // CustomSongWidget::loadSongInfoFinished from 0x100620210 to 0x1006204c1 (689 bytes) // // 2 xrefs: // > sub_1006204D0 @ 0x1006204dc // > @ 0x100982238 // // 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 CustomSongWidget::loadSongInfoFinished(CustomSongWidget *a1, SongInfoObject *a2) { SongInfoObject *v2; // r14 int m_songID; // eax __int64 *left; // rdi __int64 *v6; // rdx int v7; // esi cocos2d::extension::CCScale9Sprite *m_bgSpr; // rdi SongInfoObject *m_songInfoObject; // rdi int v10; // eax std::__compressed_pair *>> *p_pair1; // r15 __int64 *v12; // rdx std::__tree_end_node *> *v13; // rcx std::__tree_end_node *> *v14; // rax MusicDownloadManager *v15; // rax cocos2d::CCSprite *m_sliderBar; // r14 __m128 width_low; // xmm0 __m128 v18; // xmm2 cocos2d::CCDelayTime *v19; // r14 cocos2d::CCCallFunc *v20; // rax cocos2d::CCSequence *v21; // rax std::__compressed_pair *>> *v22; // rcx bool v23; // zf MusicDownloadManager *v24; // rax _BYTE v25[40]; // [rsp+8h] [rbp-28h] BYREF v2 = a2; m_songID = a2->m_songID; left = (__int64 *)a1->m_nextSongIDs.__tree_.__pair1_.__value_.__left_; if ( !left ) { LABEL_7: if ( a1->m_customSongID != m_songID || a1->m_customSongID == 0 ) return; ((void (__fastcall *)(cocos2d::CCLabelBMFont *, _QWORD))a1->m_errorLabel->setVisible)(a1->m_errorLabel, 0); m_bgSpr = a1->m_bgSpr; if ( m_bgSpr ) ((void (__fastcall *)(cocos2d::extension::CCScale9Sprite *, _QWORD))m_bgSpr->setVisible)(m_bgSpr, 0); m_songInfoObject = a1->m_songInfoObject; if ( m_songInfoObject == v2 ) { v2 = a1->m_songInfoObject; if ( m_songInfoObject ) { LABEL_16: v10 = v2->m_songID; LABEL_28: a1->m_customSongID = v10; CustomSongWidget::updateSongInfo(a1); if ( a1->m_isNotDownloading ) { a1->m_isNotDownloading = 0; v15 = MusicDownloadManager::sharedState(); MusicDownloadManager::downloadSong(v15, a1->m_customSongID); m_sliderBar = a1->m_sliderBar; width_low = (__m128)LODWORD(a1->m_sliderGroove->m_obRect.size.width); width_low.f32[0] = width_low.f32[0] + -4.0; v18 = width_low; v18.f32[0] = fminf(width_low.f32[0] * 0.0, width_low.f32[0]); sub_10028CC00((__int64)v25, 0.0, 0.0, v18, (__m128)0x41000000u); ((void (__fastcall *)(cocos2d::CCSprite *, _BYTE *))m_sliderBar->setTextureRect)(m_sliderBar, v25); ((void (__fastcall *)(cocos2d::CCSprite *, __int64))a1->m_sliderGroove->setVisible)(a1->m_sliderGroove, 1); cocos2d::CCNode::unschedule( a1, (cocos2d::SEL_SCHEDULE)(unsigned __int64)CustomSongWidget::updateDownloadProgress); cocos2d::CCNode::schedule_1( a1, (cocos2d::SEL_SCHEDULE)(unsigned __int64)CustomSongWidget::updateDownloadProgress, 0.033333335); } v19 = cocos2d::CCDelayTime::create(0.0); v20 = cocos2d::CCCallFunc::create(a1, (cocos2d::SEL_CallFunc)(unsigned __int64)CustomSongWidget::updateSongInfo); v21 = sub_1003B5760(v19, v20, 0); cocos2d::CCNode::runAction(a1, v21); return; } } else { if ( v2 ) { cocos2d::CCObject::retain(v2); m_songInfoObject = a1->m_songInfoObject; } if ( m_songInfoObject ) cocos2d::CCObject::release(m_songInfoObject); a1->m_songInfoObject = v2; if ( v2 ) goto LABEL_16; } v10 = 0; goto LABEL_28; } v6 = left; while ( 1 ) { v7 = *((_DWORD *)v6 + 7); if ( m_songID >= v7 ) break; LABEL_3: v6 = (__int64 *)*v6; if ( !v6 ) goto LABEL_7; } if ( m_songID > v7 ) { ++v6; goto LABEL_3; } p_pair1 = &a1->m_nextSongIDs.__tree_.__pair1_; v12 = left; do { if ( *((_DWORD *)v12 + 7) >= m_songID ) p_pair1 = (std::__compressed_pair *>> *)v12; v12 = (__int64 *)v12[*((_DWORD *)v12 + 7) < m_songID]; } while ( v12 ); if ( p_pair1 != &a1->m_nextSongIDs.__tree_.__pair1_ && m_songID >= SHIDWORD(p_pair1[3].__value_.__left_) ) { v13 = (std::__tree_end_node *> *)p_pair1[1].__value_.__left_; if ( v13 ) { do { v14 = v13; v13 = (std::__tree_end_node *> *)v13->__left_; } while ( v13 ); } else { v22 = p_pair1; do { v14 = (std::__tree_end_node *> *)v22[2].__value_.__left_; v23 = v14->__left_ == (std::__tree_end_node *>::pointer)v22; v22 = (std::__compressed_pair *>> *)v14; } while ( !v23 ); } if ( (std::__compressed_pair *>> *)a1->m_nextSongIDs.__tree_.__begin_node_ == p_pair1 ) a1->m_nextSongIDs.__tree_.__begin_node_ = v14; --a1->m_nextSongIDs.__tree_.__pair3_.__value_; sub_100165F60(left, (__int64 *)p_pair1); operator delete(p_pair1); } v24 = MusicDownloadManager::sharedState(); MusicDownloadManager::downloadSong(v24, v2->m_songID); }
GD Web Decomp Icon

GD Web Decomp

Raw Source