{"type": "func", "start": 4296893212, "end": 4296893436, "name": "MusicDownloadManager::getCustomSFXRoot", "pseudocode": "// \n// MusicDownloadManager::getCustomSFXRoot from 0x1001d631c to 0x1001d63fc (224 bytes)\n// \n// 12 xrefs:\n// > MusicDownloadManager::createCustomSFXFolder @ 0x1001d698c\n// > MusicDownloadManager::createCustomSFXPlacement @ 0x1001d6ba0\n// > MusicDownloadManager::getCustomSFXLocationText @ 0x1001d75d8\n// > MusicDownloadManager::importCustomSFXSetup @ 0x1001d810c\n// > sub_1001D852C @ 0x1001d855c\n// > MusicDownloadManager::decodeCustomSFX @ 0x1001d9afc\n// > sub_1001F489C @ 0x1001f492c\n// > sub_1001F489C @ 0x1001f4b94\n// > sub_1001F489C @ 0x1001f4cb8\n// > sub_1001F6604 @ 0x1001f66e8\n// > sub_1001F6DF0 @ 0x1001f6ee4\n// > sub_100528E64 @ 0x100528f28\n// \n// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:00:25 +0000\n// \n\n__int64 __fastcall MusicDownloadManager::getCustomSFXRoot(__int64 a1)\n{\n  __int64 v2; // x0\n  __int64 v3; // x20\n  int v4; // w20\n  void *__p[2]; // [xsp+8h] [xbp-28h] BYREF\n  char v7; // [xsp+1Fh] [xbp-11h]\n\n  if ( !*(_QWORD *)(a1 + 824) )\n  {\n    v2 = cocos2d::CCDictionary::create(a1);\n    *(_QWORD *)(a1 + 824) = v2;\n    cocos2d::CCObject::retain(v2);\n    sub_100009900(__p, \"Custom\");\n    v3 = sub_1001D6418(1, __p, 0);\n    if ( v7 < 0 )\n      operator delete(__p[0]);\n    *(_DWORD *)(v3 + 76) = 1;\n    cocos2d::CCDictionary::setObject_1(*(_QWORD *)(a1 + 824), v3, 1);\n    if ( *(int *)(a1 + 832) <= 2 )\n    {\n      v4 = rand();\n      *(_DWORD *)(a1 + 832) = (rand() | (v4 << 15)) % 7900000 + 100000;\n    }\n  }\n  return cocos2d::CCDictionary::objectForKey_1(*(_QWORD *)(a1 + 824), 1);\n}", "assembly": "; \n; MusicDownloadManager::getCustomSFXRoot from 0x1001d631c to 0x1001d63fc (224 bytes)\n; \n; 12 xrefs:\n; > MusicDownloadManager::createCustomSFXFolder @ 0x1001d698c\n; > MusicDownloadManager::createCustomSFXPlacement @ 0x1001d6ba0\n; > MusicDownloadManager::getCustomSFXLocationText @ 0x1001d75d8\n; > MusicDownloadManager::importCustomSFXSetup @ 0x1001d810c\n; > sub_1001D852C @ 0x1001d855c\n; > MusicDownloadManager::decodeCustomSFX @ 0x1001d9afc\n; > sub_1001F489C @ 0x1001f492c\n; > sub_1001F489C @ 0x1001f4b94\n; > sub_1001F489C @ 0x1001f4cb8\n; > sub_1001F6604 @ 0x1001f66e8\n; > sub_1001F6DF0 @ 0x1001f6ee4\n; > sub_100528E64 @ 0x100528f28\n; \n; This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:00:25 +0000\n; \nSUB             SP, SP, #0x40                                          ; +0x0, 0x1001d631c\nSTP             X20, X19, [SP,#0x30+var_10]                            ; +0x4, 0x1001d6320\nSTP             X29, X30, [SP,#0x30+var_s0]                            ; +0x8, 0x1001d6324\nADD             X29, SP, #0x30                                         ; +0xc, 0x1001d6328\nMOV             X19, X0                                                ; +0x10, 0x1001d632c\nLDR             X8, [X0,#0x338]                                        ; +0x14, 0x1001d6330\nCBNZ            X8, loc_1001D63E0                                      ; +0x18, 0x1001d6334\nBL              cocos2d__CCDictionary__create                          ; +0x1c, 0x1001d6338\nSTR             X0, [X19,#0x338]                                       ; +0x20, 0x1001d633c\nBL              cocos2d__CCObject__retain                              ; +0x24, 0x1001d6340\nADRL            X1, aCustom; \"Custom\"                                  ; +0x28, 0x1001d6344\nADD             X0, SP, #0x30+__p; int                                 ; +0x30, 0x1001d634c\nBL              sub_100009900                                          ; +0x34, 0x1001d6350\nADD             X1, SP, #0x30+__p                                      ; +0x38, 0x1001d6354\nMOV             W0, #1                                                 ; +0x3c, 0x1001d6358\nMOV             W2, #0                                                 ; +0x40, 0x1001d635c\nBL              sub_1001D6418                                          ; +0x44, 0x1001d6360\nMOV             X20, X0                                                ; +0x48, 0x1001d6364\nLDRSB           W8, [SP,#0x30+var_11]                                  ; +0x4c, 0x1001d6368\nTBZ             W8, #0x1F, loc_1001D6378                               ; +0x50, 0x1001d636c\nLDR             X0, [SP,#0x30+__p]; __p                                ; +0x54, 0x1001d6370\nBL              __ZdlPv; operator delete(void *)                       ; +0x58, 0x1001d6374\nMOV             W8, #1                                                 ; +0x5c, 0x1001d6378\nSTR             W8, [X20,#0x4C]                                        ; +0x60, 0x1001d637c\nLDR             X0, [X19,#0x338]                                       ; +0x64, 0x1001d6380\nMOV             X1, X20                                                ; +0x68, 0x1001d6384\nMOV             W2, #1                                                 ; +0x6c, 0x1001d6388\nBL              cocos2d__CCDictionary__setObject_1                     ; +0x70, 0x1001d638c\nLDR             W8, [X19,#0x340]                                       ; +0x74, 0x1001d6390\nCMP             W8, #2                                                 ; +0x78, 0x1001d6394\nB.GT            loc_1001D63E0                                          ; +0x7c, 0x1001d6398\nBL              _rand                                                  ; +0x80, 0x1001d639c\nMOV             X20, X0                                                ; +0x84, 0x1001d63a0\nBL              _rand                                                  ; +0x88, 0x1001d63a4\nORR             W8, W0, W20,LSL#15                                     ; +0x8c, 0x1001d63a8\nMOV             W9, #0x87EAABF9                                        ; +0x90, 0x1001d63ac\nSMULL           X9, W8, W9                                             ; +0x98, 0x1001d63b4\nLSR             X9, X9, #0x20 ; ' '                                    ; +0x9c, 0x1001d63b8\nADD             W9, W9, W8                                             ; +0xa0, 0x1001d63bc\nASR             W10, W9, #0x16                                         ; +0xa4, 0x1001d63c0\nADD             W9, W10, W9,LSR#31                                     ; +0xa8, 0x1001d63c4\nMOV             W10, #0x788B60                                         ; +0xac, 0x1001d63c8\nMSUB            W8, W9, W10, W8                                        ; +0xb4, 0x1001d63d0\nADD             W8, W8, #0x18,LSL#12                                   ; +0xb8, 0x1001d63d4\nADD             W8, W8, #0x6A0                                         ; +0xbc, 0x1001d63d8\nSTR             W8, [X19,#0x340]                                       ; +0xc0, 0x1001d63dc\nLDR             X0, [X19,#0x338]                                       ; +0xc4, 0x1001d63e0\nMOV             W1, #1                                                 ; +0xc8, 0x1001d63e4\nBL              cocos2d__CCDictionary__objectForKey_1                  ; +0xcc, 0x1001d63e8\nLDP             X29, X30, [SP,#0x30+var_s0]                            ; +0xd0, 0x1001d63ec\nLDP             X20, X19, [SP,#0x30+var_10]                            ; +0xd4, 0x1001d63f0\nADD             SP, SP, #0x40 ; '@'                                    ; +0xd8, 0x1001d63f4\nRET                                                                    ; +0xdc, 0x1001d63f8", "xrefs": ["MusicDownloadManager::createCustomSFXFolder @ 0x1001d698c", "MusicDownloadManager::createCustomSFXPlacement @ 0x1001d6ba0", "MusicDownloadManager::getCustomSFXLocationText @ 0x1001d75d8", "MusicDownloadManager::importCustomSFXSetup @ 0x1001d810c", "sub_1001D852C @ 0x1001d855c", "MusicDownloadManager::decodeCustomSFX @ 0x1001d9afc", "sub_1001F489C @ 0x1001f492c", "sub_1001F489C @ 0x1001f4b94", "sub_1001F489C @ 0x1001f4cb8", "sub_1001F6604 @ 0x1001f66e8", "sub_1001F6DF0 @ 0x1001f6ee4", "sub_100528E64 @ 0x100528f28"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}