{"type": "func", "start": 5373456320, "end": 5373456657, "name": "MusicDownloadManager::isCustomSFXInScope", "pseudocode": "// \n// MusicDownloadManager::isCustomSFXInScope from 0x140486fc0 to 0x140487111 (337 bytes)\n// \n// 4 xrefs:\n// > MusicDownloadManager::rebuildCustomSFXMappings @ 0x140487412\n// > <???> @ 0x1408d056c\n// > <???> @ 0x1408d0580\n// > <???> @ 0x140928c70\n// \n// This function is hookable on this platform (idp: pc, 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:32:47 +0000\n// \n\nchar __fastcall MusicDownloadManager::isCustomSFXInScope(__int64 a1, __int64 a2, _QWORD *a3)\n{\n  __int64 *v7; // rdx\n  __int64 *v8; // r8\n  __int64 *v9; // rax\n  char v10; // r9\n  int *v11; // rcx\n  cocos2d::CCDictionary *v12; // rcx\n  int v13; // ebx\n  struct cocos2d::CCObject *v14; // r8\n  __int64 *v15; // rax\n  __int64 *i; // rcx\n  cocos2d::CCDictionary *v17; // rcx\n\n  if ( !a3[1] )\n    return 0;\n  v7 = (__int64 *)*a3;\n  v8 = v7;\n  v9 = (__int64 *)v7[1];\n  v10 = *((_BYTE *)v9 + 25);\n  if ( !v10 )\n  {\n    v11 = (int *)v7[1];\n    do\n    {\n      if ( v11[7] >= -1 )\n        v8 = (__int64 *)v11;\n      else\n        v11 += 4;\n      v11 = *(int **)v11;\n    }\n    while ( !*((_BYTE *)v11 + 25) );\n  }\n  if ( !*((_BYTE *)v8 + 25) && *((int *)v8 + 7) <= -1 )\n    return 1;\n  if ( !v10 )\n  {\n    do\n    {\n      if ( *((int *)v9 + 7) >= 1 )\n        v7 = v9;\n      else\n        v9 += 2;\n      v9 = (__int64 *)*v9;\n    }\n    while ( !*((_BYTE *)v9 + 25) );\n  }\n  if ( !*((_BYTE *)v7 + 25) && *((int *)v7 + 7) <= 1 )\n    return 1;\n  v12 = *(cocos2d::CCDictionary **)(a1 + 920);\n  if ( v12 )\n  {\n    if ( *(int *)(a2 + 60) > 0 )\n    {\n      v13 = 0;\n      v14 = cocos2d::CCDictionary::objectForKey(v12, *(int *)(a2 + 60));\n      if ( v14 )\n      {\n        while ( v13 < 100 )\n        {\n          v15 = (__int64 *)*a3;\n          for ( i = *(__int64 **)(*a3 + 8LL); !*((_BYTE *)i + 25); i = (__int64 *)*i )\n          {\n            if ( *((_DWORD *)i + 7) >= *((_DWORD *)v14 + 19) )\n              v15 = i;\n            else\n              i += 2;\n          }\n          if ( !*((_BYTE *)v15 + 25) && *((_DWORD *)v14 + 19) >= *((_DWORD *)v15 + 7) )\n            return 1;\n          v17 = *(cocos2d::CCDictionary **)(a1 + 920);\n          if ( v17 )\n          {\n            if ( *((int *)v14 + 15) > 0 )\n            {\n              ++v13;\n              v14 = cocos2d::CCDictionary::objectForKey(v17, *((int *)v14 + 15));\n              if ( v14 )\n                continue;\n            }\n          }\n          return 0;\n        }\n      }\n    }\n  }\n  return 0;\n}", "assembly": "; \n; MusicDownloadManager::isCustomSFXInScope from 0x140486fc0 to 0x140487111 (337 bytes)\n; \n; 4 xrefs:\n; > MusicDownloadManager::rebuildCustomSFXMappings @ 0x140487412\n; > <???> @ 0x1408d056c\n; > <???> @ 0x1408d0580\n; > <???> @ 0x140928c70\n; \n; This function is hookable on this platform (idp: pc, 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:32:47 +0000\n; \nmov     [rsp+arg_8], rsi                                               ; +0x0, 0x140486fc0\npush    rdi                                                            ; +0x5, 0x140486fc5\nsub     rsp, 20h                                                       ; +0x6, 0x140486fc6\ncmp     qword ptr [r8+8], 0                                            ; +0xa, 0x140486fca\nmov     rdi, r8                                                        ; +0xf, 0x140486fcf\nmov     r10, rdx                                                       ; +0x12, 0x140486fd2\nmov     rsi, rcx                                                       ; +0x15, 0x140486fd5\njnz     short loc_140486FE7                                            ; +0x18, 0x140486fd8\nxor     al, al                                                         ; +0x1a, 0x140486fda\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x1c, 0x140486fdc\nadd     rsp, 20h                                                       ; +0x21, 0x140486fe1\npop     rdi                                                            ; +0x25, 0x140486fe5\nretn                                                                   ; +0x26, 0x140486fe6\nmov     rdx, [r8]                                                      ; +0x27, 0x140486fe7\nmov     r8, rdx                                                        ; +0x2a, 0x140486fea\nmov     rax, [rdx+8]                                                   ; +0x2d, 0x140486fed\nmovzx   r9d, byte ptr [rax+19h]                                        ; +0x31, 0x140486ff1\ntest    r9b, r9b                                                       ; +0x36, 0x140486ff6\njnz     short loc_140487018                                            ; +0x39, 0x140486ff9\nmov     rcx, rax                                                       ; +0x3b, 0x140486ffb\nxchg    ax, ax                                                         ; +0x3e, 0x140486ffe\ncmp     dword ptr [rcx+1Ch], 0FFFFFFFFh                                ; +0x40, 0x140487000\njge     short loc_14048700C                                            ; +0x44, 0x140487004\nadd     rcx, 10h                                                       ; +0x46, 0x140487006\njmp     short loc_14048700F                                            ; +0x4a, 0x14048700a\nmov     r8, rcx                                                        ; +0x4c, 0x14048700c\nmov     rcx, [rcx]                                                     ; +0x4f, 0x14048700f\ncmp     byte ptr [rcx+19h], 0                                          ; +0x52, 0x140487012\njz      short loc_140487000                                            ; +0x56, 0x140487016\ncmp     byte ptr [r8+19h], 0                                           ; +0x58, 0x140487018\nmov     [rsp+28h+arg_0], rbx                                           ; +0x5d, 0x14048701d\njnz     short loc_14048702F                                            ; +0x62, 0x140487022\ncmp     dword ptr [r8+1Ch], 0FFFFFFFFh                                 ; +0x64, 0x140487024\njle     loc_1404870FF                                                  ; +0x69, 0x140487029\ntest    r9b, r9b                                                       ; +0x6f, 0x14048702f\njnz     short loc_14048704C                                            ; +0x72, 0x140487032\ncmp     dword ptr [rax+1Ch], 1                                         ; +0x74, 0x140487034\njge     short loc_140487040                                            ; +0x78, 0x140487038\nadd     rax, 10h                                                       ; +0x7a, 0x14048703a\njmp     short loc_140487043                                            ; +0x7e, 0x14048703e\nmov     rdx, rax                                                       ; +0x80, 0x140487040\nmov     rax, [rax]                                                     ; +0x83, 0x140487043\ncmp     byte ptr [rax+19h], 0                                          ; +0x86, 0x140487046\njz      short loc_140487034                                            ; +0x8a, 0x14048704a\ncmp     byte ptr [rdx+19h], 0                                          ; +0x8c, 0x14048704c\njnz     short loc_14048705C                                            ; +0x90, 0x140487050\ncmp     dword ptr [rdx+1Ch], 1                                         ; +0x92, 0x140487052\njle     loc_1404870FF                                                  ; +0x96, 0x140487056\nmov     rcx, [rsi+398h]                                                ; +0x9c, 0x14048705c\ntest    rcx, rcx                                                       ; +0xa3, 0x140487063\njz      loc_1404870ED                                                  ; +0xa6, 0x140487066\nmovsxd  rax, dword ptr [r10+3Ch]                                       ; +0xac, 0x14048706c\ntest    eax, eax                                                       ; +0xb0, 0x140487070\njle     short loc_1404870ED                                            ; +0xb2, 0x140487072\nmov     rdx, rax                                                       ; +0xb4, 0x140487074\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0xb7, 0x140487077\nxor     ebx, ebx                                                       ; +0xbd, 0x14048707d\nmov     r8, rax                                                        ; +0xbf, 0x14048707f\ntest    rax, rax                                                       ; +0xc2, 0x140487082\njz      short loc_1404870ED                                            ; +0xc5, 0x140487085\ncmp     ebx, 64h ; 'd'                                                 ; +0xc7, 0x140487087\njge     short loc_1404870ED                                            ; +0xca, 0x14048708a\nmov     rax, [rdi]                                                     ; +0xcc, 0x14048708c\nmov     rcx, [rax+8]                                                   ; +0xcf, 0x14048708f\ncmp     byte ptr [rcx+19h], 0                                          ; +0xd3, 0x140487093\njnz     short loc_1404870B7                                            ; +0xd7, 0x140487097\nmov     edx, [r8+4Ch]                                                  ; +0xd9, 0x140487099\nnop     dword ptr [rax]                                                ; +0xdd, 0x14048709d\ncmp     [rcx+1Ch], edx                                                 ; +0xe0, 0x1404870a0\njge     short loc_1404870AB                                            ; +0xe3, 0x1404870a3\nadd     rcx, 10h                                                       ; +0xe5, 0x1404870a5\njmp     short loc_1404870AE                                            ; +0xe9, 0x1404870a9\nmov     rax, rcx                                                       ; +0xeb, 0x1404870ab\nmov     rcx, [rcx]                                                     ; +0xee, 0x1404870ae\ncmp     byte ptr [rcx+19h], 0                                          ; +0xf1, 0x1404870b1\njz      short loc_1404870A0                                            ; +0xf5, 0x1404870b5\ncmp     byte ptr [rax+19h], 0                                          ; +0xf7, 0x1404870b7\njnz     short loc_1404870C6                                            ; +0xfb, 0x1404870bb\nmov     eax, [rax+1Ch]                                                 ; +0xfd, 0x1404870bd\ncmp     [r8+4Ch], eax                                                  ; +0x100, 0x1404870c0\njge     short loc_1404870FF                                            ; +0x104, 0x1404870c4\nmov     rcx, [rsi+398h]                                                ; +0x106, 0x1404870c6\ntest    rcx, rcx                                                       ; +0x10d, 0x1404870cd\njz      short loc_1404870ED                                            ; +0x110, 0x1404870d0\nmovsxd  rax, dword ptr [r8+3Ch]                                        ; +0x112, 0x1404870d2\ntest    eax, eax                                                       ; +0x116, 0x1404870d6\njle     short loc_1404870ED                                            ; +0x118, 0x1404870d8\nmov     rdx, rax                                                       ; +0x11a, 0x1404870da\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0x11d, 0x1404870dd\ninc     ebx                                                            ; +0x123, 0x1404870e3\nmov     r8, rax                                                        ; +0x125, 0x1404870e5\ntest    rax, rax                                                       ; +0x128, 0x1404870e8\njnz     short loc_140487087                                            ; +0x12b, 0x1404870eb\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x12d, 0x1404870ed\nxor     al, al                                                         ; +0x132, 0x1404870f2\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x134, 0x1404870f4\nadd     rsp, 20h                                                       ; +0x139, 0x1404870f9\npop     rdi                                                            ; +0x13d, 0x1404870fd\nretn                                                                   ; +0x13e, 0x1404870fe\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x13f, 0x1404870ff\nmov     al, 1                                                          ; +0x144, 0x140487104\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x146, 0x140487106\nadd     rsp, 20h                                                       ; +0x14b, 0x14048710b\npop     rdi                                                            ; +0x14f, 0x14048710f\nretn                                                                   ; +0x150, 0x140487110", "xrefs": ["MusicDownloadManager::rebuildCustomSFXMappings @ 0x140487412", "<???> @ 0x1408d056c", "<???> @ 0x1408d0580", "<???> @ 0x140928c70"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "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"}