{"type": "func", "start": 5371226144, "end": 5371226388, "name": "GJGameLevel::syncUneditedControls", "pseudocode": "// \n// GJGameLevel::syncUneditedControls from 0x140266820 to 0x140266914 (244 bytes)\n// \n// 6 xrefs:\n// > GameLevelManager::applyLevelControlsSection @ 0x140228366\n// > GameLevelManager::onUploadLevelControlsCompleted @ 0x1402594e0\n// > GameLevelManager::onDeleteLevelControlsCompleted @ 0x140259b1d\n// > GameLevelManager::onGetLevelControlsCompleted @ 0x14025a5fa\n// > GameLevelManager::onGetLevelControlsCompleted @ 0x14025a646\n// > <???> @ 0x14091c9a0\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:28:49 +0000\n// \n\n// Hidden C++ exception states: #wind=1\nvoid __fastcall GJGameLevel::syncUneditedControls(__int64 a1)\n{\n  __int64 v2; // rcx\n  __int64 v3; // rdi\n  void *v4; // rdx\n  void *v5; // [rsp+30h] [rbp+8h]\n\n  if ( *(_DWORD *)(a1 + 972) == 5 && *(_BYTE *)(a1 + 1072) && !*(_BYTE *)(a1 + 2100) )\n  {\n    v2 = qword_14090BFD0;\n    if ( !qword_14090BFD0 )\n    {\n      v5 = operator new(0x6E8u);\n      qword_14090BFD0 = GameManager::GameManager(v5);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);\n      v2 = qword_14090BFD0;\n    }\n    if ( !(unsigned __int8)GameManager::getGameVariable(v2, \"0203\") )\n    {\n      v3 = *(_QWORD *)(a1 + 2080);\n      if ( a1 + 2064 != a1 + 2024 )\n      {\n        v4 = (void *)(a1 + 2024);\n        if ( *(_QWORD *)(a1 + 2048) > 0xFu )\n          v4 = *(void **)(a1 + 2024);\n        sub_1400405A0((void **)(a1 + 2064), v4, *(_QWORD *)(a1 + 2040));\n      }\n      if ( v3 )\n      {\n        if ( *(_QWORD *)(a1 + 2080) )\n          return;\n      }\n      else if ( *(_QWORD *)(a1 + 2080) )\n      {\n        *(_DWORD *)(a1 + 2096) = 1;\n        return;\n      }\n      *(_DWORD *)(a1 + 2096) = 0;\n    }\n  }\n}", "assembly": "; \n; GJGameLevel::syncUneditedControls from 0x140266820 to 0x140266914 (244 bytes)\n; \n; 6 xrefs:\n; > GameLevelManager::applyLevelControlsSection @ 0x140228366\n; > GameLevelManager::onUploadLevelControlsCompleted @ 0x1402594e0\n; > GameLevelManager::onDeleteLevelControlsCompleted @ 0x140259b1d\n; > GameLevelManager::onGetLevelControlsCompleted @ 0x14025a5fa\n; > GameLevelManager::onGetLevelControlsCompleted @ 0x14025a646\n; > <???> @ 0x14091c9a0\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:28:49 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x140266820\npush    rdi                                                            ; +0x5, 0x140266825\nsub     rsp, 20h                                                       ; +0x6, 0x140266826\nmov     rbx, rcx                                                       ; +0xa, 0x14026682a\ncmp     dword ptr [rcx+3CCh], 5                                        ; +0xd, 0x14026682d\njnz     loc_140266909                                                  ; +0x14, 0x140266834\ncmp     byte ptr [rcx+430h], 0                                         ; +0x1a, 0x14026683a\njz      loc_140266909                                                  ; +0x21, 0x140266841\ncmp     byte ptr [rcx+834h], 0                                         ; +0x27, 0x140266847\njnz     loc_140266909                                                  ; +0x2e, 0x14026684e\nmov     rcx, cs:qword_14090BFD0                                        ; +0x34, 0x140266854\ntest    rcx, rcx                                                       ; +0x3b, 0x14026685b\njnz     short loc_140266892                                            ; +0x3e, 0x14026685e\nmov     ecx, 6E8h; Size                                                ; +0x40, 0x140266860\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x45, 0x140266865\nmov     [rsp+28h+arg_0], rax                                           ; +0x4a, 0x14026686a\nmov     rcx, rax                                                       ; +0x4f, 0x14026686f\ncall    GameManager__GameManager                                       ; +0x52, 0x140266872\nnop                                                                    ; +0x57, 0x140266877\nmov     cs:qword_14090BFD0, rax                                        ; +0x58, 0x140266878\nmov     rcx, [rax]                                                     ; +0x5f, 0x14026687f\nmov     rdx, [rcx+48h]                                                 ; +0x62, 0x140266882\nmov     rcx, rax                                                       ; +0x66, 0x140266886\ncall    rdx                                                            ; +0x69, 0x140266889\nmov     rcx, cs:qword_14090BFD0                                        ; +0x6b, 0x14026688b\nlea     rdx, a0203; \"0203\"                                             ; +0x72, 0x140266892\ncall    GameManager__getGameVariable                                   ; +0x79, 0x140266899\ntest    al, al                                                         ; +0x7e, 0x14026689e\njnz     short loc_140266909                                            ; +0x80, 0x1402668a0\nmov     rdi, [rbx+820h]                                                ; +0x82, 0x1402668a2\nlea     r8, [rbx+7E8h]                                                 ; +0x89, 0x1402668a9\nlea     rcx, [rbx+810h]; void *                                        ; +0x90, 0x1402668b0\ncmp     rcx, r8                                                        ; +0x97, 0x1402668b7\njz      short loc_1402668D2                                            ; +0x9a, 0x1402668ba\nmov     rdx, r8                                                        ; +0x9c, 0x1402668bc\ncmp     qword ptr [r8+18h], 0Fh                                        ; +0x9f, 0x1402668bf\njbe     short loc_1402668C9                                            ; +0xa4, 0x1402668c4\nmov     rdx, [r8]; Src                                                 ; +0xa6, 0x1402668c6\nmov     r8, [r8+10h]; Size                                             ; +0xa9, 0x1402668c9\ncall    sub_1400405A0                                                  ; +0xad, 0x1402668cd\ntest    rdi, rdi                                                       ; +0xb2, 0x1402668d2\njnz     short loc_1402668F5                                            ; +0xb5, 0x1402668d5\ncmp     [rbx+820h], rdi                                                ; +0xb7, 0x1402668d7\njz      short loc_1402668FF                                            ; +0xbe, 0x1402668de\nmov     dword ptr [rbx+830h], 1                                        ; +0xc0, 0x1402668e0\nmov     rbx, [rsp+28h+arg_8]                                           ; +0xca, 0x1402668ea\nadd     rsp, 20h                                                       ; +0xcf, 0x1402668ef\npop     rdi                                                            ; +0xd3, 0x1402668f3\nretn                                                                   ; +0xd4, 0x1402668f4\ncmp     qword ptr [rbx+820h], 0                                        ; +0xd5, 0x1402668f5\njnz     short loc_140266909                                            ; +0xdd, 0x1402668fd\nmov     dword ptr [rbx+830h], 0                                        ; +0xdf, 0x1402668ff\nmov     rbx, [rsp+28h+arg_8]                                           ; +0xe9, 0x140266909\nadd     rsp, 20h                                                       ; +0xee, 0x14026690e\npop     rdi                                                            ; +0xf2, 0x140266912\nretn                                                                   ; +0xf3, 0x140266913", "xrefs": ["GameLevelManager::applyLevelControlsSection @ 0x140228366", "GameLevelManager::onUploadLevelControlsCompleted @ 0x1402594e0", "GameLevelManager::onDeleteLevelControlsCompleted @ 0x140259b1d", "GameLevelManager::onGetLevelControlsCompleted @ 0x14025a5fa", "GameLevelManager::onGetLevelControlsCompleted @ 0x14025a646", "<???> @ 0x14091c9a0"], "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"}