{"type": "func", "start": 5372114128, "end": 5372114301, "name": "MusicDownloadManager::pathForSong", "pseudocode": "// \n// MusicDownloadManager::pathForSong from 0x14033f4d0 to 0x14033f57d (173 bytes)\n// \n// 21 xrefs:\n// > FindBPMLayer::playMusic @ 0x14009bd3b\n// > CustomSongCell::onDelete @ 0x1400b492a\n// > CustomSongCell::onDelete @ 0x1400b4a0c\n// > SongSelectNode::getSongFileName @ 0x1400c7e18\n// > CustomSongWidget::deleteSong @ 0x1400ca06a\n// > CustomSongWidget::deleteSong @ 0x1400ca14c\n// > CustomSongWidget::onPlayback @ 0x1400caf31\n// > CustomSongWidget::onPlayback @ 0x1400cb1c1\n// > CustomSongWidget::updatePlaybackBtn @ 0x1400cb2f3\n// > GJGameLevel::getAudioFileName @ 0x14016cf2b\n// > GameManager::getMenuMusicFile @ 0x14017b785\n// > GJBaseGameLayer::activateSongTrigger @ 0x140241862\n// > GJBaseGameLayer::processActivatedAudioTriggers @ 0x140243ad4\n// > GJSongBrowser::FLAlert_Clicked @ 0x1402b7bb4\n// > MusicDownloadManager::onDownloadSongCompleted @ 0x14033edb0\n// > MusicDownloadManager::onDownloadSongCompleted @ 0x14033ef03\n// > MusicDownloadManager::isSongDownloaded @ 0x14033f2a4\n// > PlayLayer::togglePracticeMode @ 0x1403b9fbd\n// > SetupSongTriggerPopup::init @ 0x14045d3a5\n// > SetupSongTriggerPopup::onPlayback @ 0x14045d86e\n// > <???> @ 0x1406d56e4\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\n// Hidden C++ exception states: #wind=2\n_QWORD *__fastcall MusicDownloadManager::pathForSong(__int64 a1, _QWORD *a2, int a3)\n{\n  void **v5; // rax\n  void *v6; // rdx\n  char *v7; // rdx\n  _QWORD v9[4]; // [rsp+30h] [rbp-38h] BYREF\n\n  MusicDownloadManager::pathForSongFolder(a1, a2, a3);\n  v5 = (void **)GameToolbox::intToString(v9, a3);\n  v6 = v5;\n  if ( (unsigned __int64)v5[3] > 0xF )\n    v6 = *v5;\n  sub_140041270(a2, v6, (size_t)v5[2]);\n  sub_14003A830((__int64)v9);\n  v7 = \".ogg\";\n  if ( a3 <= 10000000 )\n    v7 = \".mp3\";\n  sub_140041270(a2, v7, 4u);\n  return a2;\n}", "assembly": "; \n; MusicDownloadManager::pathForSong from 0x14033f4d0 to 0x14033f57d (173 bytes)\n; \n; 21 xrefs:\n; > FindBPMLayer::playMusic @ 0x14009bd3b\n; > CustomSongCell::onDelete @ 0x1400b492a\n; > CustomSongCell::onDelete @ 0x1400b4a0c\n; > SongSelectNode::getSongFileName @ 0x1400c7e18\n; > CustomSongWidget::deleteSong @ 0x1400ca06a\n; > CustomSongWidget::deleteSong @ 0x1400ca14c\n; > CustomSongWidget::onPlayback @ 0x1400caf31\n; > CustomSongWidget::onPlayback @ 0x1400cb1c1\n; > CustomSongWidget::updatePlaybackBtn @ 0x1400cb2f3\n; > GJGameLevel::getAudioFileName @ 0x14016cf2b\n; > GameManager::getMenuMusicFile @ 0x14017b785\n; > GJBaseGameLayer::activateSongTrigger @ 0x140241862\n; > GJBaseGameLayer::processActivatedAudioTriggers @ 0x140243ad4\n; > GJSongBrowser::FLAlert_Clicked @ 0x1402b7bb4\n; > MusicDownloadManager::onDownloadSongCompleted @ 0x14033edb0\n; > MusicDownloadManager::onDownloadSongCompleted @ 0x14033ef03\n; > MusicDownloadManager::isSongDownloaded @ 0x14033f2a4\n; > PlayLayer::togglePracticeMode @ 0x1403b9fbd\n; > SetupSongTriggerPopup::init @ 0x14045d3a5\n; > SetupSongTriggerPopup::onPlayback @ 0x14045d86e\n; > <???> @ 0x1406d56e4\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nmov     [rsp+arg_18], rbx                                              ; +0x0, 0x14033f4d0\npush    rdi                                                            ; +0x5, 0x14033f4d5\nsub     rsp, 60h                                                       ; +0x6, 0x14033f4d6\nmov     rax, cs:__security_cookie                                      ; +0xa, 0x14033f4da\nxor     rax, rsp                                                       ; +0x11, 0x14033f4e1\nmov     [rsp+68h+var_18], rax                                          ; +0x14, 0x14033f4e4\nmov     edi, r8d                                                       ; +0x19, 0x14033f4e9\nmov     rbx, rdx                                                       ; +0x1c, 0x14033f4ec\nmov     [rsp+68h+var_40], rdx                                          ; +0x1f, 0x14033f4ef\nmov     [rsp+68h+var_48], 0                                            ; +0x24, 0x14033f4f4\ncall    MusicDownloadManager__pathForSongFolder                        ; +0x2c, 0x14033f4fc\nmov     [rsp+68h+var_48], 1                                            ; +0x31, 0x14033f501\nmov     edx, edi                                                       ; +0x39, 0x14033f509\nlea     rcx, [rsp+68h+var_38]                                          ; +0x3b, 0x14033f50b\ncall    GameToolbox__intToString                                       ; +0x40, 0x14033f510\nnop                                                                    ; +0x45, 0x14033f515\nmov     rdx, rax                                                       ; +0x46, 0x14033f516\ncmp     qword ptr [rax+18h], 0Fh                                       ; +0x49, 0x14033f519\njbe     short loc_14033F523                                            ; +0x4e, 0x14033f51e\nmov     rdx, [rax]; void *                                             ; +0x50, 0x14033f520\nmov     r8, [rax+10h]; Size                                            ; +0x53, 0x14033f523\nmov     rcx, rbx; Src                                                  ; +0x57, 0x14033f527\ncall    sub_140041270                                                  ; +0x5a, 0x14033f52a\nnop                                                                    ; +0x5f, 0x14033f52f\nlea     rcx, [rsp+68h+var_38]                                          ; +0x60, 0x14033f530\ncall    sub_14003A830                                                  ; +0x65, 0x14033f535\nmov     r8d, 4; Size                                                   ; +0x6a, 0x14033f53a\nmov     rcx, rbx; Src                                                  ; +0x70, 0x14033f540\ncmp     edi, 989680h                                                   ; +0x73, 0x14033f543\nlea     rdx, aOgg; \".ogg\"                                              ; +0x79, 0x14033f549\njg      short loc_14033F559                                            ; +0x80, 0x14033f550\nlea     rdx, aMp3; \".mp3\"                                              ; +0x82, 0x14033f552\ncall    sub_140041270                                                  ; +0x89, 0x14033f559\nmov     rax, rbx                                                       ; +0x8e, 0x14033f55e\nmov     rcx, [rsp+68h+var_18]                                          ; +0x91, 0x14033f561\nxor     rcx, rsp; StackCookie                                          ; +0x96, 0x14033f566\ncall    __security_check_cookie                                        ; +0x99, 0x14033f569\nmov     rbx, [rsp+68h+arg_18]                                          ; +0x9e, 0x14033f56e\nadd     rsp, 60h                                                       ; +0xa6, 0x14033f576\npop     rdi                                                            ; +0xaa, 0x14033f57a\nretn                                                                   ; +0xab, 0x14033f57b\ndb 0CCh                                                                ; +0xac, 0x14033f57c", "xrefs": ["FindBPMLayer::playMusic @ 0x14009bd3b", "CustomSongCell::onDelete @ 0x1400b492a", "CustomSongCell::onDelete @ 0x1400b4a0c", "SongSelectNode::getSongFileName @ 0x1400c7e18", "CustomSongWidget::deleteSong @ 0x1400ca06a", "CustomSongWidget::deleteSong @ 0x1400ca14c", "CustomSongWidget::onPlayback @ 0x1400caf31", "CustomSongWidget::onPlayback @ 0x1400cb1c1", "CustomSongWidget::updatePlaybackBtn @ 0x1400cb2f3", "GJGameLevel::getAudioFileName @ 0x14016cf2b", "GameManager::getMenuMusicFile @ 0x14017b785", "GJBaseGameLayer::activateSongTrigger @ 0x140241862", "GJBaseGameLayer::processActivatedAudioTriggers @ 0x140243ad4", "GJSongBrowser::FLAlert_Clicked @ 0x1402b7bb4", "MusicDownloadManager::onDownloadSongCompleted @ 0x14033edb0", "MusicDownloadManager::onDownloadSongCompleted @ 0x14033ef03", "MusicDownloadManager::isSongDownloaded @ 0x14033f2a4", "PlayLayer::togglePracticeMode @ 0x1403b9fbd", "SetupSongTriggerPopup::init @ 0x14045d3a5", "SetupSongTriggerPopup::onPlayback @ 0x14045d86e", "<???> @ 0x1406d56e4"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}