{"type": "func", "start": 5370330480, "end": 5370330885, "name": "EditorSFXManager::overwriteMyConfigFromLive", "pseudocode": "// \n// EditorSFXManager::overwriteMyConfigFromLive from 0x14018bd70 to 0x14018bf05 (405 bytes)\n// \n// 2 xrefs:\n// > EditorSoundConfigInfoLayer::FLAlert_Clicked @ 0x140198282\n// > <???> @ 0x140918f8c\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:27:41 +0000\n// \n\n// Hidden C++ exception states: #wind=3\nchar __fastcall EditorSFXManager::overwriteMyConfigFromLive(_QWORD *a1, int a2, void **a3)\n{\n  int v5; // esi\n  struct cocos2d::CCObject *MyConfig; // r15\n  void **v8; // rax\n  char v9; // bl\n  int v10; // ebp\n  _QWORD *v11; // r14\n  _QWORD *i; // rbx\n  cocos2d::CCArray **v13; // rdi\n  __int64 v14; // rax\n  __int64 v15; // rbx\n  void *v16; // rdx\n  _BYTE v17[16]; // [rsp+38h] [rbp-70h] BYREF\n  __int64 v18; // [rsp+48h] [rbp-60h]\n  void *v19[4]; // [rsp+58h] [rbp-50h] BYREF\n\n  v5 = 0;\n  MyConfig = EditorSFXManager::getMyConfig((__int64)a1, a2);\n  if ( MyConfig )\n  {\n    v8 = EditorSFXManager::serializeAll(a1, v19);\n    cocos2d::ZipUtils::compressString(v17, v8, 0, 0xFFFFFFFFLL, 0);\n    sub_14003D310((__int64)v19);\n    if ( v18 )\n    {\n      v10 = 0;\n      v11 = (_QWORD *)a1[1];\n      for ( i = (_QWORD *)*v11; i != v11; i = (_QWORD *)*i )\n      {\n        v13 = (cocos2d::CCArray **)i[3];\n        if ( v13 && *v13 && cocos2d::CCArray::count(*v13) )\n        {\n          ++v5;\n          v10 += cocos2d::CCArray::count(*v13);\n        }\n      }\n      v14 = sub_14003F4F0((__int64)v19, (__int64)v17);\n      v15 = v14;\n      if ( (struct cocos2d::CCObject *)((char *)MyConfig + 512) != (struct cocos2d::CCObject *)v14 )\n      {\n        v16 = (void *)v14;\n        if ( *(_QWORD *)(v14 + 24) > 0xFu )\n          v16 = *(void **)v14;\n        sub_1400405A0((void **)MyConfig + 64, v16, *(_QWORD *)(v14 + 16));\n      }\n      sub_14003D310(v15);\n      *((_BYTE *)MyConfig + 544) = 1;\n      *((_DWORD *)MyConfig + 90) = v10;\n      *((_DWORD *)MyConfig + 89) = v5;\n      ++*((_DWORD *)MyConfig + 83);\n      *((_DWORD *)MyConfig + 93) = time64(nullptr);\n      v9 = 1;\n    }\n    else\n    {\n      if ( a3 )\n        sub_1400405A0(a3, \"No active sound actions to save.\", 0x20u);\n      v9 = 0;\n    }\n    sub_14003D310((__int64)v17);\n    return v9;\n  }\n  else\n  {\n    if ( a3 )\n      sub_1400405A0(a3, \"List not found.\", 0xFu);\n    return 0;\n  }\n}", "assembly": "; \n; EditorSFXManager::overwriteMyConfigFromLive from 0x14018bd70 to 0x14018bf05 (405 bytes)\n; \n; 2 xrefs:\n; > EditorSoundConfigInfoLayer::FLAlert_Clicked @ 0x140198282\n; > <???> @ 0x140918f8c\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:27:41 +0000\n; \nmov     [rsp+arg_18], rbx                                              ; +0x0, 0x14018bd70\npush    rbp                                                            ; +0x5, 0x14018bd75\npush    rsi                                                            ; +0x6, 0x14018bd76\npush    rdi                                                            ; +0x7, 0x14018bd77\npush    r14                                                            ; +0x8, 0x14018bd78\npush    r15                                                            ; +0xa, 0x14018bd7a\nsub     rsp, 80h                                                       ; +0xc, 0x14018bd7c\nmov     rax, cs:__security_cookie                                      ; +0x13, 0x14018bd83\nxor     rax, rsp                                                       ; +0x1a, 0x14018bd8a\nmov     [rsp+0A8h+var_30], rax                                         ; +0x1d, 0x14018bd8d\nmov     rbx, r8                                                        ; +0x22, 0x14018bd92\nmov     r14, rcx                                                       ; +0x25, 0x14018bd95\nxor     esi, esi                                                       ; +0x28, 0x14018bd98\ncall    EditorSFXManager__getMyConfig                                  ; +0x2a, 0x14018bd9a\nmov     r15, rax                                                       ; +0x2f, 0x14018bd9f\ntest    rax, rax                                                       ; +0x32, 0x14018bda2\njnz     short loc_14018BDC8                                            ; +0x35, 0x14018bda5\ntest    rbx, rbx                                                       ; +0x37, 0x14018bda7\njz      short loc_14018BDC1                                            ; +0x3a, 0x14018bdaa\nmov     r8d, 0Fh; Size                                                 ; +0x3c, 0x14018bdac\nlea     rdx, aListNotFound_0; \"List not found.\"                        ; +0x42, 0x14018bdb2\nmov     rcx, rbx; void *                                               ; +0x49, 0x14018bdb9\ncall    sub_1400405A0                                                  ; +0x4c, 0x14018bdbc\nxor     al, al                                                         ; +0x51, 0x14018bdc1\njmp     loc_14018BEE1                                                  ; +0x53, 0x14018bdc3\nlea     rdx, [rsp+0A8h+var_50]                                         ; +0x58, 0x14018bdc8\nmov     rcx, r14                                                       ; +0x5d, 0x14018bdcd\ncall    EditorSFXManager__serializeAll                                 ; +0x60, 0x14018bdd0\nnop                                                                    ; +0x65, 0x14018bdd5\nmov     [rsp+0A8h+var_88], esi                                         ; +0x66, 0x14018bdd6\nmov     r9d, 0FFFFFFFFh                                                ; +0x6a, 0x14018bdda\nxor     r8d, r8d                                                       ; +0x70, 0x14018bde0\nmov     rdx, rax                                                       ; +0x73, 0x14018bde3\nlea     rcx, [rsp+0A8h+var_70]                                         ; +0x76, 0x14018bde6\ncall    cs:?compressString@ZipUtils@cocos2d@@SA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEBV34@_NHH@Z; cocos2d::ZipUtils::compressString(std::string const &,bool,int,int) ; +0x7b, 0x14018bdeb\nnop                                                                    ; +0x81, 0x14018bdf1\nlea     rcx, [rsp+0A8h+var_50]                                         ; +0x82, 0x14018bdf2\ncall    sub_14003D310                                                  ; +0x87, 0x14018bdf7\nnop                                                                    ; +0x8c, 0x14018bdfc\ncmp     [rsp+0A8h+var_60], 0                                           ; +0x8d, 0x14018bdfd\njnz     short loc_14018BE26                                            ; +0x93, 0x14018be03\ntest    rbx, rbx                                                       ; +0x95, 0x14018be05\njz      short loc_14018BE1F                                            ; +0x98, 0x14018be08\nmov     r8d, 20h ; ' '; Size                                           ; +0x9a, 0x14018be0a\nlea     rdx, aNoActiveSoundA; \"No active sound actions to save.\"       ; +0xa0, 0x14018be10\nmov     rcx, rbx; void *                                               ; +0xa7, 0x14018be17\ncall    sub_1400405A0                                                  ; +0xaa, 0x14018be1a\nxor     bl, bl                                                         ; +0xaf, 0x14018be1f\njmp     loc_14018BED4                                                  ; +0xb1, 0x14018be21\nmov     ebp, esi                                                       ; +0xb6, 0x14018be26\nmov     r14, [r14+8]                                                   ; +0xb8, 0x14018be28\nmov     rbx, [r14]                                                     ; +0xbc, 0x14018be2c\ncmp     rbx, r14                                                       ; +0xbf, 0x14018be2f\njz      short loc_14018BE64                                            ; +0xc2, 0x14018be32\nmov     rdi, [rbx+18h]                                                 ; +0xc4, 0x14018be34\ntest    rdi, rdi                                                       ; +0xc8, 0x14018be38\njz      short loc_14018BE5C                                            ; +0xcb, 0x14018be3b\nmov     rcx, [rdi]                                                     ; +0xcd, 0x14018be3d\ntest    rcx, rcx                                                       ; +0xd0, 0x14018be40\njz      short loc_14018BE5C                                            ; +0xd3, 0x14018be43\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xd5, 0x14018be45\ntest    eax, eax                                                       ; +0xdb, 0x14018be4b\njz      short loc_14018BE5C                                            ; +0xdd, 0x14018be4d\ninc     esi                                                            ; +0xdf, 0x14018be4f\nmov     rcx, [rdi]                                                     ; +0xe1, 0x14018be51\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xe4, 0x14018be54\nadd     ebp, eax                                                       ; +0xea, 0x14018be5a\nmov     rbx, [rbx]                                                     ; +0xec, 0x14018be5c\ncmp     rbx, r14                                                       ; +0xef, 0x14018be5f\njnz     short loc_14018BE34                                            ; +0xf2, 0x14018be62\nlea     rdx, [rsp+0A8h+var_70]                                         ; +0xf4, 0x14018be64\nlea     rcx, [rsp+0A8h+var_50]                                         ; +0xf9, 0x14018be69\ncall    sub_14003F4F0                                                  ; +0xfe, 0x14018be6e\nmov     rbx, rax                                                       ; +0x103, 0x14018be73\nmov     [rsp+0A8h+var_78], rax                                         ; +0x106, 0x14018be76\nlea     rcx, [r15+200h]; void *                                        ; +0x10b, 0x14018be7b\ncmp     rcx, rax                                                       ; +0x112, 0x14018be82\njz      short loc_14018BE9E                                            ; +0x115, 0x14018be85\nmov     rdx, rax                                                       ; +0x117, 0x14018be87\ncmp     qword ptr [rax+18h], 0Fh                                       ; +0x11a, 0x14018be8a\njbe     short loc_14018BE94                                            ; +0x11f, 0x14018be8f\nmov     rdx, [rax]; Src                                                ; +0x121, 0x14018be91\nmov     r8, [rax+10h]; Size                                            ; +0x124, 0x14018be94\ncall    sub_1400405A0                                                  ; +0x128, 0x14018be98\nnop                                                                    ; +0x12d, 0x14018be9d\nmov     rcx, rbx                                                       ; +0x12e, 0x14018be9e\ncall    sub_14003D310                                                  ; +0x131, 0x14018bea1\nmov     byte ptr [r15+220h], 1                                         ; +0x136, 0x14018bea6\nmov     [r15+168h], ebp                                                ; +0x13e, 0x14018beae\nmov     [r15+164h], esi                                                ; +0x145, 0x14018beb5\ninc     dword ptr [r15+14Ch]                                           ; +0x14c, 0x14018bebc\nxor     ecx, ecx; Time                                                 ; +0x153, 0x14018bec3\ncall    cs:_time64                                                     ; +0x155, 0x14018bec5\nmov     [r15+174h], eax                                                ; +0x15b, 0x14018becb\nmov     bl, 1                                                          ; +0x162, 0x14018bed2\nlea     rcx, [rsp+0A8h+var_70]                                         ; +0x164, 0x14018bed4\ncall    sub_14003D310                                                  ; +0x169, 0x14018bed9\nmovzx   eax, bl                                                        ; +0x16e, 0x14018bede\nmov     rcx, [rsp+0A8h+var_30]                                         ; +0x171, 0x14018bee1\nxor     rcx, rsp; StackCookie                                          ; +0x176, 0x14018bee6\ncall    __security_check_cookie                                        ; +0x179, 0x14018bee9\nmov     rbx, [rsp+0A8h+arg_18]                                         ; +0x17e, 0x14018beee\nadd     rsp, 80h                                                       ; +0x186, 0x14018bef6\npop     r15                                                            ; +0x18d, 0x14018befd\npop     r14                                                            ; +0x18f, 0x14018beff\npop     rdi                                                            ; +0x191, 0x14018bf01\npop     rsi                                                            ; +0x192, 0x14018bf02\npop     rbp                                                            ; +0x193, 0x14018bf03\nretn                                                                   ; +0x194, 0x14018bf04", "xrefs": ["EditorSoundConfigInfoLayer::FLAlert_Clicked @ 0x140198282", "<???> @ 0x140918f8c"], "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"}