{"type": "func", "start": 4063496, "end": 4063660, "name": "CustomSongWidget::startMultiAssetDownload", "pseudocode": "// \n// CustomSongWidget::startMultiAssetDownload from 0x3e0108 to 0x3e01ac (164 bytes)\n// \n// 1 xrefs:\n// > CustomSongWidget::onDownload @ 0x3e0226\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\nvoid CustomSongWidget::startMultiAssetDownload(CustomSongWidget *a1)\n{\n  std::_rb_tree_base *p_m_header; // r6\n  std::vector<GJAssetDownloadAction> *p_m_undownloadedAssets; // r8\n  int m_parent_low; // r3\n  int v5; // r3\n  std::_rb_tree_base *i; // [sp+0h] [bp-14h] BYREF\n  int v7; // [sp+4h] [bp-10h] BYREF\n  int v8; // [sp+8h] [bp-Ch] BYREF\n\n  p_m_header = &a1->m_songs.m_header;\n  p_m_undownloadedAssets = &a1->m_undownloadedAssets;\n  a1->m_undownloadedAssets.m_finish = a1->m_undownloadedAssets.m_start;\n  for ( i = a1->m_songs.m_header.m_left; i != p_m_header; std::_Rb_tree_iterator<std::pair<int const,bool>>::operator++(&i) )\n  {\n    m_parent_low = LOBYTE(i[1].m_parent);\n    v7 = *(_DWORD *)&i[1].m_isblack;\n    if ( !m_parent_low )\n    {\n      v8 = 1;\n      std::vector<GJAssetDownloadAction>::emplace_back<int &,GJAssetType>(p_m_undownloadedAssets, &v7, &v8);\n    }\n  }\n  for ( i = a1->m_sfx.m_header.m_left;\n        i != &a1->m_sfx.m_header;\n        std::_Rb_tree_iterator<std::pair<int const,bool>>::operator++(&i) )\n  {\n    v5 = LOBYTE(i[1].m_parent);\n    v7 = *(_DWORD *)&i[1].m_isblack;\n    if ( !v5 )\n    {\n      v8 = 2;\n      std::vector<GJAssetDownloadAction>::emplace_back<int &,GJAssetType>(&a1->m_undownloadedAssets.m_start, &v7, &v8);\n    }\n  }\n  CustomSongWidget::processNextMultiAsset(a1);\n}", "assembly": "; \n; CustomSongWidget::startMultiAssetDownload from 0x3e0108 to 0x3e01ac (164 bytes)\n; \n; 1 xrefs:\n; > CustomSongWidget::onDownload @ 0x3e0226\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\nLDR             R3, =(__stack_chk_guard_ptr - 0x3E0112)                ; +0x0, 0x3e0108\nPUSH.W          {R4-R9,LR}                                             ; +0x2, 0x3e010a\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x6, 0x3e010e\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x8, 0x3e0110\nSUB             SP, SP, #0x14                                          ; +0xa, 0x3e0112\nADD.W           R6, R0, #0x17C                                         ; +0xc, 0x3e0114\nLDR             R2, [R3]                                               ; +0x10, 0x3e0118\nADD.W           R8, R0, #0x1A8                                         ; +0x12, 0x3e011a\nADD.W           R9, SP, #0x14+var_10                                   ; +0x16, 0x3e011e\nMOV             R4, R0                                                 ; +0x1a, 0x3e0122\nMOV             R5, R3                                                 ; +0x1c, 0x3e0124\nMOVS            R7, #1                                                 ; +0x1e, 0x3e0126\nSTR             R2, [SP,#0x14+var_8]                                   ; +0x20, 0x3e0128\nLDR.W           R2, [R0,#0x1A8]                                        ; +0x22, 0x3e012a\nSTR.W           R2, [R0,#0x1AC]                                        ; +0x26, 0x3e012e\nLDR.W           R2, [R0,#0x184]                                        ; +0x2a, 0x3e0132\nSTR             R2, [SP,#0x14+var_14]                                  ; +0x2e, 0x3e0136\nLDR             R3, [SP,#0x14+var_14]                                  ; +0x30, 0x3e0138\nCMP             R3, R6                                                 ; +0x32, 0x3e013a\nBEQ             loc_3E015C                                             ; +0x34, 0x3e013c\nLDR             R2, [R3,#0x10]                                         ; +0x36, 0x3e013e\nLDRB            R3, [R3,#0x14]                                         ; +0x38, 0x3e0140\nSTR             R2, [SP,#0x14+var_10]                                  ; +0x3a, 0x3e0142\nCBNZ            R3, loc_3E0154                                         ; +0x3c, 0x3e0144\nADD             R2, SP, #0x14+var_4                                    ; +0x3e, 0x3e0146\nMOV             R0, R8                                                 ; +0x40, 0x3e0148\nMOV             R1, R9                                                 ; +0x42, 0x3e014a\nSTR.W           R7, [R2,#-8]!                                          ; +0x44, 0x3e014c\nBL              _ZNSt6vectorI21GJAssetDownloadActionSaIS0_EE12emplace_backIJRi11GJAssetTypeEEEvDpOT_; std::vector<GJAssetDownloadAction>::emplace_back<int &,GJAssetType>(int &,GJAssetType &&) ; +0x48, 0x3e0150\nMOV             R0, SP                                                 ; +0x4c, 0x3e0154\nBL              _ZNSt17_Rb_tree_iteratorISt4pairIKibEEppEv; std::_Rb_tree_iterator<std::pair<int const,bool>>::operator++(void) ; +0x4e, 0x3e0156\nB               loc_3E0138                                             ; +0x52, 0x3e015a\nLDR.W           R3, [R4,#0x19C]                                        ; +0x54, 0x3e015c\nADD.W           R6, R4, #0x194                                         ; +0x58, 0x3e0160\nADD.W           R8, R4, #0x1A8                                         ; +0x5c, 0x3e0164\nADD.W           R9, SP, #0x14+var_10                                   ; +0x60, 0x3e0168\nMOVS            R7, #2                                                 ; +0x64, 0x3e016c\nSTR             R3, [SP,#0x14+var_14]                                  ; +0x66, 0x3e016e\nLDR             R3, [SP,#0x14+var_14]                                  ; +0x68, 0x3e0170\nCMP             R3, R6                                                 ; +0x6a, 0x3e0172\nBEQ             loc_3E0194                                             ; +0x6c, 0x3e0174\nLDR             R2, [R3,#0x10]                                         ; +0x6e, 0x3e0176\nLDRB            R3, [R3,#0x14]                                         ; +0x70, 0x3e0178\nSTR             R2, [SP,#0x14+var_10]                                  ; +0x72, 0x3e017a\nCBNZ            R3, loc_3E018C                                         ; +0x74, 0x3e017c\nADD             R2, SP, #0x14+var_4                                    ; +0x76, 0x3e017e\nMOV             R0, R8                                                 ; +0x78, 0x3e0180\nMOV             R1, R9                                                 ; +0x7a, 0x3e0182\nSTR.W           R7, [R2,#-8]!                                          ; +0x7c, 0x3e0184\nBL              _ZNSt6vectorI21GJAssetDownloadActionSaIS0_EE12emplace_backIJRi11GJAssetTypeEEEvDpOT_; std::vector<GJAssetDownloadAction>::emplace_back<int &,GJAssetType>(int &,GJAssetType &&) ; +0x80, 0x3e0188\nMOV             R0, SP                                                 ; +0x84, 0x3e018c\nBL              _ZNSt17_Rb_tree_iteratorISt4pairIKibEEppEv; std::_Rb_tree_iterator<std::pair<int const,bool>>::operator++(void) ; +0x86, 0x3e018e\nB               loc_3E0170                                             ; +0x8a, 0x3e0192\nMOV             R0, R4; this                                           ; +0x8c, 0x3e0194\nBL              _ZN16CustomSongWidget21processNextMultiAssetEv; CustomSongWidget::processNextMultiAsset(void) ; +0x8e, 0x3e0196\nLDR             R2, [SP,#0x14+var_8]                                   ; +0x92, 0x3e019a\nLDR             R3, [R5]                                               ; +0x94, 0x3e019c\nCMP             R2, R3                                                 ; +0x96, 0x3e019e\nBEQ             loc_3E01A6                                             ; +0x98, 0x3e01a0\nBLX             __stack_chk_fail                                       ; +0x9a, 0x3e01a2\nADD             SP, SP, #0x14                                          ; +0x9e, 0x3e01a6\nPOP.W           {R4-R9,PC}                                             ; +0xa0, 0x3e01a8", "xrefs": ["CustomSongWidget::onDownload @ 0x3e0226"], "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"}