//
// SongSelectNode::getSongFileName from 0x140168e40 to 0x140168f30 (240 bytes)
//
// 2 xrefs:
// > ??> @ 0x140744510
// > ??> @ 0x140918050
//
// 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 11:27:28 +0000
//
// Hidden C++ exception states: #wind=2
_QWORD *__fastcall SongSelectNode::getSongFileName(__int64 a1, _QWORD *a2)
{
__int64 v4; // rcx
_QWORD *v5; // rax
size_t v6; // r8
void *v8; // [rsp+28h] [rbp-40h]
_BYTE v9[32]; // [rsp+30h] [rbp-38h] BYREF
if ( *(_DWORD *)(a1 + 8) )
{
v4 = qword_14090C070;
if ( !qword_14090C070 )
{
v8 = operator new(0x3D0u);
qword_14090C070 = MusicDownloadManager::MusicDownloadManager(v8);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090C070 + 72LL))(qword_14090C070);
v4 = qword_14090C070;
}
v5 = (_QWORD *)MusicDownloadManager::pathForSong(v4, v9, *(unsigned int *)(a1 + 8));
if ( v5[3] > 0xFu )
v5 = (_QWORD *)*v5;
*(_OWORD *)a2 = 0;
a2[2] = 0;
a2[3] = 0;
v6 = -1;
do
++v6;
while ( *((_BYTE *)v5 + v6) );
sub_14003D230(a2, v5, v6);
sub_14003D310((__int64)v9);
}
else
{
GJGameLevel::getAudioFileName(*(_QWORD *)(*(_QWORD *)(a1 + 88) + 384LL));
}
return a2;
}