{"type": "func", "start": 4295016288, "end": 4295016590, "name": "EditorUI::toggleDuplicateButton", "pseudocode": "// \n// EditorUI::toggleDuplicateButton from 0x10000bf60 to 0x10000c08e (302 bytes)\n// \n// 1 xrefs:\n// > EditorUI::updateButtons @ 0x10000ae1c\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 12:18:50 +0000\n// \n\n__int64 __fastcall EditorUI::toggleDuplicateButton(_QWORD *a1)\n{\n  _BYTE *v2; // rdi\n  int v3; // eax\n  void *v4; // r14\n  unsigned __int8 v5; // r15\n  char v6; // r12\n  _BYTE *v7; // rdi\n  __int64 v8; // rdi\n  __int64 v9; // rdx\n  __int64 v10; // rax\n  unsigned int v11; // ecx\n  __int64 v12; // rcx\n  _BYTE *v13; // rdi\n  void *v14; // rsi\n  unsigned int v15; // r14d\n\n  if ( a1[187] )\n  {\n    v2 = (_BYTE *)a1[141];\n    v2[408] = 1;\nLABEL_4:\n    v4 = &unk_100A038D0;\n    v5 = -1;\n    v6 = 1;\n    goto LABEL_5;\n  }\n  v3 = sub_1007FEF90(a1[112]);\n  v2 = (_BYTE *)a1[141];\n  v2[408] = v3 != 0;\n  if ( v3 )\n    goto LABEL_4;\n  v6 = 0;\n  v4 = &unk_100A038D3;\n  v5 = -81;\nLABEL_5:\n  (*(void (__fastcall **)(_BYTE *, void *))(*(_QWORD *)v2 + 960LL))(v2, v4);\n  (*(void (__fastcall **)(_QWORD, _QWORD))(*(_QWORD *)a1[141] + 912LL))(a1[141], v5);\n  v7 = (_BYTE *)a1[142];\n  v7[408] = v6;\n  (*(void (__fastcall **)(_BYTE *, void *))(*(_QWORD *)v7 + 960LL))(v7, v4);\n  v8 = a1[142];\n  (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v8 + 912LL))(v8, v5);\n  v10 = GameManager::sharedState(v8, v5, v9);\n  v11 = *(unsigned __int8 *)(v10 + 512);\n  if ( (v11 & 1) != 0 )\n    v12 = *(_QWORD *)(v10 + 520);\n  else\n    v12 = v11 >> 1;\n  v13 = (_BYTE *)a1[143];\n  v13[408] = v12 != 0;\n  v14 = &unk_100A038D3;\n  if ( v12 )\n    v14 = &unk_100A038D0;\n  v15 = 175;\n  if ( v12 )\n    v15 = 255;\n  (*(void (__fastcall **)(_BYTE *, void *))(*(_QWORD *)v13 + 960LL))(v13, v14);\n  return (*(__int64 (__fastcall **)(_QWORD, _QWORD))(*(_QWORD *)a1[143] + 912LL))(a1[143], v15);\n}", "assembly": "; \n; EditorUI::toggleDuplicateButton from 0x10000bf60 to 0x10000c08e (302 bytes)\n; \n; 1 xrefs:\n; > EditorUI::updateButtons @ 0x10000ae1c\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 12:18:50 +0000\n; \npush    rbp                                                            ; +0x0, 0x10000bf60\nmov     rbp, rsp                                                       ; +0x1, 0x10000bf61\npush    r15                                                            ; +0x4, 0x10000bf64\npush    r14                                                            ; +0x6, 0x10000bf66\npush    r12                                                            ; +0x8, 0x10000bf68\npush    rbx                                                            ; +0xa, 0x10000bf6a\nmov     rbx, rdi                                                       ; +0xb, 0x10000bf6b\ncmp     qword ptr [rdi+5D8h], 0                                        ; +0xe, 0x10000bf6e\njz      short loc_10000BF88                                            ; +0x16, 0x10000bf76\nmov     rdi, [rbx+468h]                                                ; +0x18, 0x10000bf78\nmov     byte ptr [rdi+198h], 1                                         ; +0x1f, 0x10000bf7f\njmp     short loc_10000BFAA                                            ; +0x26, 0x10000bf86\nmov     rdi, [rbx+380h]                                                ; +0x28, 0x10000bf88\ncall    sub_1007FEF90                                                  ; +0x2f, 0x10000bf8f\nmov     rdi, [rbx+468h]                                                ; +0x34, 0x10000bf94\ntest    eax, eax                                                       ; +0x3b, 0x10000bf9b\nsetnz   byte ptr [rdi+198h]                                            ; +0x3d, 0x10000bf9d\njz      loc_10000C07C                                                  ; +0x44, 0x10000bfa4\nlea     r14, unk_100A038D0                                             ; +0x4a, 0x10000bfaa\nmov     r15b, 0FFh                                                     ; +0x51, 0x10000bfb1\nmov     r12b, 1                                                        ; +0x54, 0x10000bfb4\nmov     rax, [rdi]                                                     ; +0x57, 0x10000bfb7\nmov     rsi, r14                                                       ; +0x5a, 0x10000bfba\ncall    qword ptr [rax+3C0h]                                           ; +0x5d, 0x10000bfbd\nmov     rdi, [rbx+468h]                                                ; +0x63, 0x10000bfc3\nmov     rax, [rdi]                                                     ; +0x6a, 0x10000bfca\nmovzx   r15d, r15b                                                     ; +0x6d, 0x10000bfcd\nmov     esi, r15d                                                      ; +0x71, 0x10000bfd1\ncall    qword ptr [rax+390h]                                           ; +0x74, 0x10000bfd4\nmov     rdi, [rbx+470h]                                                ; +0x7a, 0x10000bfda\nmov     [rdi+198h], r12b                                               ; +0x81, 0x10000bfe1\nmov     rax, [rdi]                                                     ; +0x88, 0x10000bfe8\nmov     rsi, r14                                                       ; +0x8b, 0x10000bfeb\ncall    qword ptr [rax+3C0h]                                           ; +0x8e, 0x10000bfee\nmov     rdi, [rbx+470h]                                                ; +0x94, 0x10000bff4\nmov     rax, [rdi]                                                     ; +0x9b, 0x10000bffb\nmov     esi, r15d                                                      ; +0x9e, 0x10000bffe\ncall    qword ptr [rax+390h]                                           ; +0xa1, 0x10000c001\ncall    GameManager__sharedState                                       ; +0xa7, 0x10000c007\nmovzx   ecx, byte ptr [rax+200h]                                       ; +0xac, 0x10000c00c\ntest    cl, 1                                                          ; +0xb3, 0x10000c013\njnz     short loc_10000C01C                                            ; +0xb6, 0x10000c016\nshr     ecx, 1                                                         ; +0xb8, 0x10000c018\njmp     short loc_10000C023                                            ; +0xba, 0x10000c01a\nmov     rcx, [rax+208h]                                                ; +0xbc, 0x10000c01c\ntest    rcx, rcx                                                       ; +0xc3, 0x10000c023\nmov     rdi, [rbx+478h]                                                ; +0xc6, 0x10000c026\nsetnz   byte ptr [rdi+198h]                                            ; +0xcd, 0x10000c02d\nlea     rax, unk_100A038D0                                             ; +0xd4, 0x10000c034\nlea     rsi, unk_100A038D3                                             ; +0xdb, 0x10000c03b\ncmovnz  rsi, rax                                                       ; +0xe2, 0x10000c042\nmov     rax, [rdi]                                                     ; +0xe6, 0x10000c046\nmov     ecx, 0FFh                                                      ; +0xe9, 0x10000c049\nmov     r14d, 0AFh                                                     ; +0xee, 0x10000c04e\ncmovnz  r14d, ecx                                                      ; +0xf4, 0x10000c054\ncall    qword ptr [rax+3C0h]                                           ; +0xf8, 0x10000c058\nmov     rdi, [rbx+478h]                                                ; +0xfe, 0x10000c05e\nmov     rax, [rdi]                                                     ; +0x105, 0x10000c065\nmov     rax, [rax+390h]                                                ; +0x108, 0x10000c068\nmov     esi, r14d                                                      ; +0x10f, 0x10000c06f\npop     rbx                                                            ; +0x112, 0x10000c072\npop     r12                                                            ; +0x113, 0x10000c073\npop     r14                                                            ; +0x115, 0x10000c075\npop     r15                                                            ; +0x117, 0x10000c077\npop     rbp                                                            ; +0x119, 0x10000c079\njmp     rax                                                            ; +0x11a, 0x10000c07a\nxor     r12d, r12d                                                     ; +0x11c, 0x10000c07c\nlea     r14, unk_100A038D3                                             ; +0x11f, 0x10000c07f\nmov     r15b, 0AFh                                                     ; +0x126, 0x10000c086\njmp     loc_10000BFB7                                                  ; +0x129, 0x10000c089", "xrefs": ["EditorUI::updateButtons @ 0x10000ae1c"], "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"}