//
// CustomSongWidget::startDownload from 0x1006fb6d0 to 0x1006fb795 (197 bytes)
//
// 0 xrefs:
//
// 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:35:56 +0000
//
__int64 __fastcall CustomSongWidget::startDownload(__int64 a1)
{
__int64 v1; // rax
__int64 v2; // r14
__m128 v3; // xmm0
__m128 v4; // xmm2
_BYTE v6[40]; // [rsp+8h] [rbp-28h] BYREF
*(_BYTE *)(a1 + 499) = 0;
v1 = MusicDownloadManager::sharedState();
MusicDownloadManager::downloadSong(v1, *(_DWORD *)(a1 + 504));
v2 = *(_QWORD *)(a1 + 464);
v3 = (__m128)*(unsigned int *)(*(_QWORD *)(a1 + 456) + 432LL);
v3.f32[0] = v3.f32[0] + -4.0;
v4 = v3;
v4.f32[0] = fminf(v3.f32[0] * 0.0, v3.f32[0]);
sub_100278270((__int64)v6, 0.0, 0.0, v4, (__m128)0x41000000u);
(*(void (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)v2 + 1136LL))(v2, v6);
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 456) + 344LL))(*(_QWORD *)(a1 + 456), 1);
cocos2d::CCNode::unschedule(a1, (__int64)CustomSongWidget::updateDownloadProgress, 0);
return cocos2d::CCNode::schedule_1(
a1,
(__int64)CustomSongWidget::updateDownloadProgress,
0,
COERCE_DOUBLE(1023969417));
}