{"type": "func", "start": 5371402752, "end": 5371402890, "name": "EditorOptionsLayer::onButtonRows", "pseudocode": "// \n// EditorOptionsLayer::onButtonRows from 0x140291a00 to 0x140291a8a (138 bytes)\n// \n// 3 xrefs:\n// > EditorOptionsLayer::setupOptions @ 0x1402917ff\n// > EditorOptionsLayer::setupOptions @ 0x1402918b8\n// > <???> @ 0x1406d19c4\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 EditorOptionsLayer::onButtonRows(EditorOptionsLayer *a1, cocos2d::CCObject *a2)\n{\n  int v3; // eax\n  int m_buttonRows; // edx\n  int v5; // r8d\n  int v6; // edx\n  cocos2d::CCLabelBMFont *m_buttonRowsLabel; // rax\n  cocos2d::CCLabelProtocol_vtbl *v8; // rbx\n  cocos2d::CCString *v9; // rax\n  const char *CString; // rax\n\n  v3 = a2->getTag(a2);\n  m_buttonRows = a1->m_buttonRows;\n  v5 = m_buttonRows - 1;\n  v6 = m_buttonRows + 1;\n  if ( v3 != 1 )\n    v6 = v5;\n  if ( v6 < 2 )\n  {\n    v6 = 2;\n  }\n  else if ( v6 >= 3 )\n  {\n    v6 = 3;\n  }\n  m_buttonRowsLabel = a1->m_buttonRowsLabel;\n  a1->m_buttonRows = v6;\n  v8 = m_buttonRowsLabel->cocos2d::CCLabelProtocol::__vftable;\n  v9 = cocos2d::CCString::createWithFormat(\"%i\", v6);\n  CString = cocos2d::CCString::getCString(v9);\n  v8->setString(&a1->m_buttonRowsLabel->cocos2d::CCLabelProtocol, CString);\n}", "assembly": "; \n; EditorOptionsLayer::onButtonRows from 0x140291a00 to 0x140291a8a (138 bytes)\n; \n; 3 xrefs:\n; > EditorOptionsLayer::setupOptions @ 0x1402917ff\n; > EditorOptionsLayer::setupOptions @ 0x1402918b8\n; > <???> @ 0x1406d19c4\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, 0x140291a00\npush    rdi                                                            ; +0x5, 0x140291a05\nsub     rsp, 20h                                                       ; +0x6, 0x140291a06\nmov     rax, [rdx]                                                     ; +0xa, 0x140291a0a\nmov     rdi, rcx                                                       ; +0xd, 0x140291a0d\nmov     rcx, rdx                                                       ; +0x10, 0x140291a10\ncall    qword ptr [rax+38h]                                            ; +0x13, 0x140291a13\nmov     edx, [rdi+3F4h]                                                ; +0x16, 0x140291a16\nlea     r8d, [rdx-1]                                                   ; +0x1c, 0x140291a1c\ninc     edx                                                            ; +0x20, 0x140291a20\ncmp     eax, 1                                                         ; +0x22, 0x140291a22\ncmovnz  edx, r8d                                                       ; +0x25, 0x140291a25\ncmp     edx, 2                                                         ; +0x29, 0x140291a29\njl      short loc_140291A3A                                            ; +0x2c, 0x140291a2c\ncmp     edx, 3                                                         ; +0x2e, 0x140291a2e\njl      short loc_140291A3F                                            ; +0x31, 0x140291a31\nmov     edx, 3                                                         ; +0x33, 0x140291a33\njmp     short loc_140291A3F                                            ; +0x38, 0x140291a38\nmov     edx, 2                                                         ; +0x3a, 0x140291a3a\nmov     rax, [rdi+400h]                                                ; +0x3f, 0x140291a3f\nlea     rcx, aI_11; \"%i\"                                               ; +0x46, 0x140291a46\nmov     [rdi+3F4h], edx                                                ; +0x4d, 0x140291a4d\nmov     rbx, [rax+168h]                                                ; +0x53, 0x140291a53\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0x5a, 0x140291a5a\nmov     rcx, rax                                                       ; +0x60, 0x140291a60\ncall    cs:?getCString@CCString@cocos2d@@QEBAPEBDXZ; cocos2d::CCString::getCString(void) ; +0x63, 0x140291a63\nmov     rcx, [rdi+400h]                                                ; +0x69, 0x140291a69\nmov     rdx, rax                                                       ; +0x70, 0x140291a70\nadd     rcx, 168h                                                      ; +0x73, 0x140291a73\nmov     rax, [rbx]                                                     ; +0x7a, 0x140291a7a\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x7d, 0x140291a7d\nadd     rsp, 20h                                                       ; +0x82, 0x140291a82\npop     rdi                                                            ; +0x86, 0x140291a86\njmp     rax                                                            ; +0x87, 0x140291a87", "xrefs": ["EditorOptionsLayer::setupOptions @ 0x1402917ff", "EditorOptionsLayer::setupOptions @ 0x1402918b8", "<???> @ 0x1406d19c4"], "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"}