//
// CustomSFXWidget::updateDownloadProgress from 0x1400c1e20 to 0x1400c1ec4 (164 bytes)
//
// 5 xrefs:
// > CustomSFXWidget::startMonitorDownload @ 0x1400c1ba1
// > CustomSFXWidget::startMonitorDownload @ 0x1400c1bb9
// > CustomSFXWidget::updateDownloadProgress @ 0x1400c1e9d
// > CustomSFXWidget::downloadSFXFailed @ 0x1400c2741
// > ??> @ 0x1406c7fa4
//
// 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 CustomSFXWidget::updateDownloadProgress(CustomSFXWidget *a1, float a2)
{
int m_sfxID; // ebx
MusicDownloadManager *v4; // rdi
cocos2d::CCString *v5; // rax
const char *CString; // rax
__int64 AchievementsWithID; // rax
int v8; // edx
m_sfxID = a1->m_sfxObject->m_sfxID;
v4 = MusicDownloadManager::sharedState();
v5 = cocos2d::CCString::createWithFormat("sfx_%i", m_sfxID);
CString = cocos2d::CCString::getCString(v5);
AchievementsWithID = AchievementManager::getAchievementsWithID((__int64)v4, (__int64)CString);
v8 = -1;
if ( AchievementsWithID )
v8 = *(_DWORD *)(AchievementsWithID + 208);
if ( !a1->m_sfxObject || v8 == -1 )
{
cocos2d::CCNode::unschedule(a1, CustomSFXWidget::updateDownloadProgress);
CustomSFXWidget::updateSFXInfo(a1);
}
else
{
CustomSFXWidget::updateProgressBar(a1, v8);
}
}