{"type": "func", "start": 5373345104, "end": 5373345314, "name": "SetupItemEditTriggerPopup::onOpButton", "pseudocode": "// \n// SetupItemEditTriggerPopup::onOpButton from 0x14046bd50 to 0x14046be22 (210 bytes)\n// \n// 2 xrefs:\n// > SetupItemEditTriggerPopup::init @ 0x14046ba47\n// > <???> @ 0x1406db1c8\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\nvoid SetupItemEditTriggerPopup::onOpButton(SetupItemEditTriggerPopup *a1, cocos2d::CCObject *a2)\n{\n  __int64 v4; // rdi\n  int v5; // ebx\n  int v6; // eax\n  SetupItemEditTriggerPopup *v7; // rcx\n\n  v4 = (unsigned int)a2->getTag(a2);\n  v5 = (int)a1->getValue(a1, v4) + 1;\n  if ( (unsigned int)(v4 - 485) <= 1 )\n  {\n    if ( v5 > 3 )\n      v5 = 0;\n  }\n  else if ( (unsigned int)(v4 - 578) <= 1 )\n  {\n    v6 = 0;\n    if ( v5 <= 2 )\n      v6 = v5;\n    v5 = v6;\n  }\n  else if ( v5 > 4 )\n  {\n    v5 = 0;\n  }\n  if ( (_DWORD)v4 == 481 )\n  {\n    if ( v5 < 1 )\n      v5 = 1;\n  }\n  else if ( (_DWORD)v4 == 482 && v5 < 3 )\n  {\n    v5 = 3;\n  }\n  SetupTriggerPopup::updateValue(a1, v4, (float)v5);\n  SetupItemEditTriggerPopup::updateOpButton(v7, (CCMenuItemSpriteExtra *)a2, v5, v4);\n  SetupItemEditTriggerPopup::updateFormulaLabel(a1);\n}", "assembly": "; \n; SetupItemEditTriggerPopup::onOpButton from 0x14046bd50 to 0x14046be22 (210 bytes)\n; \n; 2 xrefs:\n; > SetupItemEditTriggerPopup::init @ 0x14046ba47\n; > <???> @ 0x1406db1c8\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\nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x14046bd50\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x14046bd55\nmov     [rsp+arg_10], rdi                                              ; +0xa, 0x14046bd5a\npush    r14                                                            ; +0xf, 0x14046bd5f\nsub     rsp, 20h                                                       ; +0x11, 0x14046bd61\nmov     rax, [rdx]                                                     ; +0x15, 0x14046bd65\nmov     rsi, rcx                                                       ; +0x18, 0x14046bd68\nmov     rcx, rdx                                                       ; +0x1b, 0x14046bd6b\nmov     r14, rdx                                                       ; +0x1e, 0x14046bd6e\ncall    qword ptr [rax+38h]                                            ; +0x21, 0x14046bd71\nmov     r8, [rsi]                                                      ; +0x24, 0x14046bd74\nmov     rcx, rsi                                                       ; +0x27, 0x14046bd77\nmov     edx, eax                                                       ; +0x2a, 0x14046bd7a\nmov     edi, eax                                                       ; +0x2c, 0x14046bd7c\ncall    qword ptr [r8+470h]                                            ; +0x2e, 0x14046bd7e\ncvttss2si ebx, xmm0                                                    ; +0x35, 0x14046bd85\nlea     ecx, [rdi-1E5h]                                                ; +0x39, 0x14046bd89\ninc     ebx                                                            ; +0x3f, 0x14046bd8f\ncmp     ecx, 1                                                         ; +0x41, 0x14046bd91\njbe     short loc_14046BDB8                                            ; +0x44, 0x14046bd94\nlea     ecx, [rdi-242h]                                                ; +0x46, 0x14046bd96\ncmp     ecx, 1                                                         ; +0x4c, 0x14046bd9c\njbe     short loc_14046BDAC                                            ; +0x4f, 0x14046bd9f\ncmp     ebx, 4                                                         ; +0x51, 0x14046bda1\njle     short loc_14046BDC0                                            ; +0x54, 0x14046bda4\nxor     eax, eax                                                       ; +0x56, 0x14046bda6\nmov     ebx, eax                                                       ; +0x58, 0x14046bda8\njmp     short loc_14046BDC0                                            ; +0x5a, 0x14046bdaa\nxor     eax, eax                                                       ; +0x5c, 0x14046bdac\ncmp     ebx, 2                                                         ; +0x5e, 0x14046bdae\ncmovle  eax, ebx                                                       ; +0x61, 0x14046bdb1\nmov     ebx, eax                                                       ; +0x64, 0x14046bdb4\njmp     short loc_14046BDC0                                            ; +0x66, 0x14046bdb6\nxor     eax, eax                                                       ; +0x68, 0x14046bdb8\ncmp     ebx, 3                                                         ; +0x6a, 0x14046bdba\ncmovg   ebx, eax                                                       ; +0x6d, 0x14046bdbd\ncmp     edi, 1E1h                                                      ; +0x70, 0x14046bdc0\njnz     short loc_14046BDD4                                            ; +0x76, 0x14046bdc6\ncmp     ebx, 1                                                         ; +0x78, 0x14046bdc8\njge     short loc_14046BDE6                                            ; +0x7b, 0x14046bdcb\nmov     ebx, 1                                                         ; +0x7d, 0x14046bdcd\njmp     short loc_14046BDE6                                            ; +0x82, 0x14046bdd2\ncmp     edi, 1E2h                                                      ; +0x84, 0x14046bdd4\njnz     short loc_14046BDE6                                            ; +0x8a, 0x14046bdda\nmov     eax, 3                                                         ; +0x8c, 0x14046bddc\ncmp     ebx, eax                                                       ; +0x91, 0x14046bde1\ncmovl   ebx, eax                                                       ; +0x93, 0x14046bde3\nmovd    xmm2, ebx                                                      ; +0x96, 0x14046bde6\nmov     edx, edi                                                       ; +0x9a, 0x14046bdea\ncvtdq2ps xmm2, xmm2                                                    ; +0x9c, 0x14046bdec\nmov     rcx, rsi                                                       ; +0x9f, 0x14046bdef\ncall    SetupTriggerPopup__updateValue                                 ; +0xa2, 0x14046bdf2\nmov     r9d, edi                                                       ; +0xa7, 0x14046bdf7\nmov     r8d, ebx                                                       ; +0xaa, 0x14046bdfa\nmov     rdx, r14                                                       ; +0xad, 0x14046bdfd\ncall    SetupItemEditTriggerPopup__updateOpButton                      ; +0xb0, 0x14046be00\nmov     rcx, rsi                                                       ; +0xb5, 0x14046be05\nmov     rbx, [rsp+28h+arg_0]                                           ; +0xb8, 0x14046be08\nmov     rsi, [rsp+28h+arg_8]                                           ; +0xbd, 0x14046be0d\nmov     rdi, [rsp+28h+arg_10]                                          ; +0xc2, 0x14046be12\nadd     rsp, 20h                                                       ; +0xc7, 0x14046be17\npop     r14                                                            ; +0xcb, 0x14046be1b\njmp     SetupItemEditTriggerPopup__updateFormulaLabel                  ; +0xcd, 0x14046be1d", "xrefs": ["SetupItemEditTriggerPopup::init @ 0x14046ba47", "<???> @ 0x1406db1c8"], "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"}