{"type": "func", "start": 5372105184, "end": 5372105597, "name": "MusicDownloadManager::init", "pseudocode": "// \n// MusicDownloadManager::init from 0x14033d1e0 to 0x14033d37d (413 bytes)\n// \n// 6 xrefs:\n// > MusicDownloadManager::sharedState @ 0x14033cd61\n// > MusicDownloadManager::sharedState @ 0x14033cd52\n// > <???> @ 0x1405ad878\n// > <???> @ 0x140694db0\n// > <???> @ 0x140694dc0\n// > <???> @ 0x1406d55a0\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\nbool MusicDownloadManager::init(MusicDownloadManager *a1)\n{\n  bool result; // al\n  __int64 v3; // rcx\n  cocos2d::CCDictionary *v4; // rax\n  __int64 v5; // rcx\n  cocos2d::CCArray *v6; // rax\n  __int128 *v7; // rax\n  __int64 v8; // rdx\n  __int128 *v9; // rcx\n  __int128 v10; // xmm0\n  __int128 v11; // xmm1\n  __int128 v12; // xmm0\n  __int128 v13; // xmm1\n  __int128 v14; // xmm0\n  __int128 v15; // xmm1\n  __int128 v16; // xmm0\n  __int128 v17; // xmm1\n  unsigned __int8 *v18; // rbx\n  unsigned __int8 *v19; // rbx\n  _BYTE v20[16]; // [rsp+20h] [rbp-468h] BYREF\n  _OWORD v21[2]; // [rsp+30h] [rbp-458h] BYREF\n  int v22; // [rsp+50h] [rbp-438h]\n  char v23; // [rsp+54h] [rbp-434h] BYREF\n  _BYTE v24[1040]; // [rsp+60h] [rbp-428h] BYREF\n  __int64 v25; // [rsp+470h] [rbp-18h] BYREF\n\n  result = cocos2d::CCNode::init(a1);\n  if ( result )\n  {\n    v4 = (cocos2d::CCDictionary *)cocos2d::CCDictionary::create(v3);\n    a1->m_activeDownloads = v4;\n    cocos2d::CCObject::retain(v4);\n    v6 = (cocos2d::CCArray *)cocos2d::CCArray::create(v5);\n    a1->m_musicDownloadDelegates = v6;\n    cocos2d::CCObject::retain(v6);\n    v7 = (__int128 *)v24;\n    v8 = 8;\n    v9 = (__int128 *)&unk_140623B10;\n    do\n    {\n      v7 += 8;\n      v10 = *v9;\n      v11 = v9[1];\n      v9 += 8;\n      *(v7 - 8) = v10;\n      v12 = *(v9 - 6);\n      *(v7 - 7) = v11;\n      v13 = *(v9 - 5);\n      *(v7 - 6) = v12;\n      v14 = *(v9 - 4);\n      *(v7 - 5) = v13;\n      v15 = *(v9 - 3);\n      *(v7 - 4) = v14;\n      v16 = *(v9 - 2);\n      *(v7 - 3) = v15;\n      v17 = *(v9 - 1);\n      *(v7 - 2) = v16;\n      *(v7 - 1) = v17;\n      --v8;\n    }\n    while ( v8 );\n    *v7 = *v9;\n    sub_14005E0D0(&a1->m_resourceSfxUnorderedSet._Traitsobj._Mypair._Myval2._Myval2);\n    v18 = v24;\n    do\n    {\n      sub_140060D70((__int64)&a1->m_resourceSfxUnorderedSet, (__int64)v20, v18);\n      v18 += 4;\n    }\n    while ( v18 != (unsigned __int8 *)&v25 );\n    v21[0] = _mm_load_si128((const __m128i *)&xmmword_140624050);\n    v22 = 10006555;\n    v21[1] = _mm_load_si128((const __m128i *)&xmmword_140624060);\n    sub_14005E0D0(&a1->m_resourceSongUnorderedSet._Traitsobj._Mypair._Myval2._Myval2);\n    v19 = (unsigned __int8 *)v21;\n    do\n    {\n      sub_140060D70((__int64)&a1->m_resourceSongUnorderedSet, (__int64)v20, v19);\n      v19 += 4;\n    }\n    while ( v19 != (unsigned __int8 *)&v23 );\n    return 1;\n  }\n  return result;\n}", "assembly": "; \n; MusicDownloadManager::init from 0x14033d1e0 to 0x14033d37d (413 bytes)\n; \n; 6 xrefs:\n; > MusicDownloadManager::sharedState @ 0x14033cd61\n; > MusicDownloadManager::sharedState @ 0x14033cd52\n; > <???> @ 0x1405ad878\n; > <???> @ 0x140694db0\n; > <???> @ 0x140694dc0\n; > <???> @ 0x1406d55a0\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\npush    rsi                                                            ; +0x0, 0x14033d1e0\nsub     rsp, 480h                                                      ; +0x2, 0x14033d1e2\nmov     rax, cs:__security_cookie                                      ; +0x9, 0x14033d1e9\nxor     rax, rsp                                                       ; +0x10, 0x14033d1f0\nmov     [rsp+488h+var_18], rax                                         ; +0x13, 0x14033d1f3\nmov     rsi, rcx                                                       ; +0x1b, 0x14033d1fb\ncall    cs:__imp_?init@CCNode@cocos2d@@UEAA_NXZ; cocos2d::CCNode::init(void) ; +0x1e, 0x14033d1fe\ntest    al, al                                                         ; +0x24, 0x14033d204\njz      loc_14033D364                                                  ; +0x26, 0x14033d206\nmov     [rsp+488h+arg_8], rbx                                          ; +0x2c, 0x14033d20c\nmov     [rsp+488h+arg_10], rdi                                         ; +0x34, 0x14033d214\ncall    cs:?create@CCDictionary@cocos2d@@SAPEAV12@XZ; cocos2d::CCDictionary::create(void) ; +0x3c, 0x14033d21c\nmov     rcx, rax                                                       ; +0x42, 0x14033d222\nmov     [rsi+148h], rax                                                ; +0x45, 0x14033d225\ncall    cs:?retain@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::retain(void) ; +0x4c, 0x14033d22c\ncall    cs:?create@CCArray@cocos2d@@SAPEAV12@XZ; cocos2d::CCArray::create(void) ; +0x52, 0x14033d232\nmov     rcx, rax                                                       ; +0x58, 0x14033d238\nmov     [rsi+150h], rax                                                ; +0x5b, 0x14033d23b\ncall    cs:?retain@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::retain(void) ; +0x62, 0x14033d242\nlea     rax, [rsp+488h+var_428]                                        ; +0x68, 0x14033d248\nmov     edx, 8                                                         ; +0x6d, 0x14033d24d\nlea     rcx, unk_140623B10                                             ; +0x72, 0x14033d252\nnop     dword ptr [rax+00000000h]                                      ; +0x79, 0x14033d259\nlea     rax, [rax+80h]                                                 ; +0x80, 0x14033d260\nmovups  xmm0, xmmword ptr [rcx]                                        ; +0x87, 0x14033d267\nmovups  xmm1, xmmword ptr [rcx+10h]                                    ; +0x8a, 0x14033d26a\nlea     rcx, [rcx+80h]                                                 ; +0x8e, 0x14033d26e\nmovups  xmmword ptr [rax-80h], xmm0                                    ; +0x95, 0x14033d275\nmovups  xmm0, xmmword ptr [rcx-60h]                                    ; +0x99, 0x14033d279\nmovups  xmmword ptr [rax-70h], xmm1                                    ; +0x9d, 0x14033d27d\nmovups  xmm1, xmmword ptr [rcx-50h]                                    ; +0xa1, 0x14033d281\nmovups  xmmword ptr [rax-60h], xmm0                                    ; +0xa5, 0x14033d285\nmovups  xmm0, xmmword ptr [rcx-40h]                                    ; +0xa9, 0x14033d289\nmovups  xmmword ptr [rax-50h], xmm1                                    ; +0xad, 0x14033d28d\nmovups  xmm1, xmmword ptr [rcx-30h]                                    ; +0xb1, 0x14033d291\nmovups  xmmword ptr [rax-40h], xmm0                                    ; +0xb5, 0x14033d295\nmovups  xmm0, xmmword ptr [rcx-20h]                                    ; +0xb9, 0x14033d299\nmovups  xmmword ptr [rax-30h], xmm1                                    ; +0xbd, 0x14033d29d\nmovups  xmm1, xmmword ptr [rcx-10h]                                    ; +0xc1, 0x14033d2a1\nmovups  xmmword ptr [rax-20h], xmm0                                    ; +0xc5, 0x14033d2a5\nmovups  xmmword ptr [rax-10h], xmm1                                    ; +0xc9, 0x14033d2a9\nsub     rdx, 1                                                         ; +0xcd, 0x14033d2ad\njnz     short loc_14033D260                                            ; +0xd1, 0x14033d2b1\nmovups  xmm0, xmmword ptr [rcx]                                        ; +0xd3, 0x14033d2b3\nlea     rcx, [rsi+1E0h]                                                ; +0xd6, 0x14033d2b6\nmovups  xmmword ptr [rax], xmm0                                        ; +0xdd, 0x14033d2bd\ncall    sub_14005E0D0                                                  ; +0xe0, 0x14033d2c0\nlea     rbx, [rsp+488h+var_428]                                        ; +0xe5, 0x14033d2c5\nnop     word ptr [rax+rax+00h]                                         ; +0xea, 0x14033d2ca\nmov     r8, rbx                                                        ; +0xf0, 0x14033d2d0\nlea     rdx, [rsp+488h+var_468]                                        ; +0xf3, 0x14033d2d3\nlea     rcx, [rsi+1E0h]                                                ; +0xf8, 0x14033d2d8\ncall    sub_140060D70                                                  ; +0xff, 0x14033d2df\nlea     rax, [rsp+488h+var_18]                                         ; +0x104, 0x14033d2e4\nadd     rbx, 4                                                         ; +0x10c, 0x14033d2ec\ncmp     rbx, rax                                                       ; +0x110, 0x14033d2f0\njnz     short loc_14033D2D0                                            ; +0x113, 0x14033d2f3\nmovdqa  xmm0, cs:xmmword_140624050                                     ; +0x115, 0x14033d2f5\nlea     rcx, [rsi+220h]                                                ; +0x11d, 0x14033d2fd\nmovdqa  xmm1, cs:xmmword_140624060                                     ; +0x124, 0x14033d304\nmovdqu  [rsp+488h+var_458], xmm0                                       ; +0x12c, 0x14033d30c\nmov     [rsp+488h+var_438], 98B01Bh                                    ; +0x132, 0x14033d312\nmovdqu  [rsp+488h+var_448], xmm1                                       ; +0x13a, 0x14033d31a\ncall    sub_14005E0D0                                                  ; +0x140, 0x14033d320\nlea     rbx, [rsp+488h+var_458]                                        ; +0x145, 0x14033d325\nnop     word ptr [rax+rax+00h]                                         ; +0x14a, 0x14033d32a\nmov     r8, rbx                                                        ; +0x150, 0x14033d330\nlea     rdx, [rsp+488h+var_468]                                        ; +0x153, 0x14033d333\nlea     rcx, [rsi+220h]                                                ; +0x158, 0x14033d338\ncall    sub_140060D70                                                  ; +0x15f, 0x14033d33f\nlea     rax, [rsp+488h+var_434]                                        ; +0x164, 0x14033d344\nadd     rbx, 4                                                         ; +0x169, 0x14033d349\ncmp     rbx, rax                                                       ; +0x16d, 0x14033d34d\njnz     short loc_14033D330                                            ; +0x170, 0x14033d350\nmov     rdi, [rsp+488h+arg_10]                                         ; +0x172, 0x14033d352\nmov     al, 1                                                          ; +0x17a, 0x14033d35a\nmov     rbx, [rsp+488h+arg_8]                                          ; +0x17c, 0x14033d35c\nmov     rcx, [rsp+488h+var_18]                                         ; +0x184, 0x14033d364\nxor     rcx, rsp; StackCookie                                          ; +0x18c, 0x14033d36c\ncall    __security_check_cookie                                        ; +0x18f, 0x14033d36f\nadd     rsp, 480h                                                      ; +0x194, 0x14033d374\npop     rsi                                                            ; +0x19b, 0x14033d37b\nretn                                                                   ; +0x19c, 0x14033d37c", "xrefs": ["MusicDownloadManager::sharedState @ 0x14033cd61", "MusicDownloadManager::sharedState @ 0x14033cd52", "<???> @ 0x1405ad878", "<???> @ 0x140694db0", "<???> @ 0x140694dc0", "<???> @ 0x1406d55a0"], "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"}