{"type": "func", "start": 4300119792, "end": 4300120136, "name": "BrowseSmartTemplateLayer::goToPage", "pseudocode": "// \n// BrowseSmartTemplateLayer::goToPage from 0x1004e9ef0 to 0x1004ea048 (344 bytes)\n// \n// 3 xrefs:\n// > BrowseSmartTemplateLayer::init @ 0x1004e94f2\n// > BrowseSmartTemplateLayer::onClick @ 0x1004ea437\n// > BrowseSmartKeyLayer::init @ 0x1004eb312\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 __fastcall BrowseSmartTemplateLayer::goToPage(BrowseSmartTemplateLayer *a1, int a2)\n{\n  BrowseSmartTemplateLayer *v2; // rbx\n  unsigned int v3; // eax\n  bool v4; // cf\n  unsigned int v5; // r14d\n  __int64 v6; // r15\n  unsigned int v7; // r12d\n  __int64 v8; // rbx\n  int m_page; // [rsp+14h] [rbp-2Ch]\n\n  v2 = a1;\n  a1->m_page = a2;\n  v3 = sub_100720070(a1->m_pages) - 1;\n  if ( a2 < 0 || (v4 = v3 < a2, v3 = 0, v4) )\n    a1->m_page = v3;\n  if ( (unsigned int)sub_100720070(a1->m_pages) )\n  {\n    v5 = 0;\n    do\n    {\n      m_page = v2->m_page;\n      v6 = sub_1007200C0(v2->m_pages, v5);\n      if ( (unsigned int)sub_100720070(v6) )\n      {\n        v7 = 0;\n        do\n        {\n          v8 = sub_1007200C0(v6, v7);\n          (*(void (__fastcall **)(__int64, bool))(*(_QWORD *)v8 + 328LL))(v8, m_page == v5);\n          (*(void (__fastcall **)(__int64, bool))(*(_QWORD *)v8 + 1040LL))(v8, m_page == v5);\n          ++v7;\n        }\n        while ( v7 < (unsigned int)sub_100720070(v6) );\n      }\n      ++v5;\n      v2 = a1;\n    }\n    while ( v5 < (unsigned int)sub_100720070(a1->m_pages) );\n  }\n  if ( (unsigned int)sub_100720070(v2->m_pages) >= 2 )\n  {\n    BrowseSmartTemplateLayer::updateDots(v2);\n  }\n  else\n  {\n    ((void (__fastcall *)(cocos2d::CCNode *, _QWORD))v2->m_prevPageBtn->setVisible)(v2->m_prevPageBtn, 0);\n    ((void (__fastcall *)(cocos2d::CCNode *, _QWORD))v2->m_nextPageBtn->setVisible)(v2->m_nextPageBtn, 0);\n  }\n}", "assembly": "; \n; BrowseSmartTemplateLayer::goToPage from 0x1004e9ef0 to 0x1004ea048 (344 bytes)\n; \n; 3 xrefs:\n; > BrowseSmartTemplateLayer::init @ 0x1004e94f2\n; > BrowseSmartTemplateLayer::onClick @ 0x1004ea437\n; > BrowseSmartKeyLayer::init @ 0x1004eb312\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\npush    rbp                                                            ; +0x0, 0x1004e9ef0\nmov     rbp, rsp                                                       ; +0x1, 0x1004e9ef1\npush    r15                                                            ; +0x4, 0x1004e9ef4\npush    r14                                                            ; +0x6, 0x1004e9ef6\npush    r13                                                            ; +0x8, 0x1004e9ef8\npush    r12                                                            ; +0xa, 0x1004e9efa\npush    rbx                                                            ; +0xc, 0x1004e9efc\nsub     rsp, 18h                                                       ; +0xd, 0x1004e9efd\nmov     r14d, esi                                                      ; +0x11, 0x1004e9f01\nmov     rbx, rdi                                                       ; +0x14, 0x1004e9f04\nmov     [rdi+288h], esi                                                ; +0x17, 0x1004e9f07\nmov     rdi, [rdi+280h]                                                ; +0x1d, 0x1004e9f0d\ncall    sub_100720070                                                  ; +0x24, 0x1004e9f14\ndec     eax                                                            ; +0x29, 0x1004e9f19\ntest    r14d, r14d                                                     ; +0x2b, 0x1004e9f1b\njs      short loc_1004E9F2A                                            ; +0x2e, 0x1004e9f1e\ncmp     eax, r14d                                                      ; +0x30, 0x1004e9f20\nmov     eax, 0                                                         ; +0x33, 0x1004e9f23\njnb     short loc_1004E9F30                                            ; +0x38, 0x1004e9f28\nmov     [rbx+288h], eax                                                ; +0x3a, 0x1004e9f2a\nmov     rdi, [rbx+280h]                                                ; +0x40, 0x1004e9f30\ncall    sub_100720070                                                  ; +0x47, 0x1004e9f37\ntest    eax, eax                                                       ; +0x4c, 0x1004e9f3c\njz      loc_1004E9FEC                                                  ; +0x4e, 0x1004e9f3e\nxor     r14d, r14d                                                     ; +0x54, 0x1004e9f44\nmov     [rbp+var_38], rbx                                              ; +0x57, 0x1004e9f47\njmp     short loc_1004E9F6C                                            ; +0x5b, 0x1004e9f4b\nalign 10h                                                              ; +0x5d, 0x1004e9f4d\ninc     r14d                                                           ; +0x60, 0x1004e9f50\nmov     rbx, [rbp+var_38]                                              ; +0x63, 0x1004e9f53\nmov     rdi, [rbx+280h]                                                ; +0x67, 0x1004e9f57\ncall    sub_100720070                                                  ; +0x6e, 0x1004e9f5e\ncmp     r14d, eax                                                      ; +0x73, 0x1004e9f63\njnb     loc_1004E9FEC                                                  ; +0x76, 0x1004e9f66\nmov     eax, [rbx+288h]                                                ; +0x7c, 0x1004e9f6c\nmov     [rbp+var_2C], eax                                              ; +0x82, 0x1004e9f72\nmov     rdi, [rbx+280h]                                                ; +0x85, 0x1004e9f75\nmov     esi, r14d                                                      ; +0x8c, 0x1004e9f7c\ncall    sub_1007200C0                                                  ; +0x8f, 0x1004e9f7f\nmov     r15, rax                                                       ; +0x94, 0x1004e9f84\nmov     rdi, rax                                                       ; +0x97, 0x1004e9f87\ncall    sub_100720070                                                  ; +0x9a, 0x1004e9f8a\ntest    eax, eax                                                       ; +0x9f, 0x1004e9f8f\njz      short loc_1004E9F50                                            ; +0xa1, 0x1004e9f91\nxor     r12d, r12d                                                     ; +0xa3, 0x1004e9f93\nnop     word ptr [rax+rax+00000000h]                                   ; +0xa6, 0x1004e9f96\nxor     r13d, r13d                                                     ; +0xb0, 0x1004e9fa0\ncmp     [rbp+var_2C], r14d                                             ; +0xb3, 0x1004e9fa3\nsetz    r13b                                                           ; +0xb7, 0x1004e9fa7\nmov     rdi, r15                                                       ; +0xbb, 0x1004e9fab\nmov     esi, r12d                                                      ; +0xbe, 0x1004e9fae\ncall    sub_1007200C0                                                  ; +0xc1, 0x1004e9fb1\nmov     rbx, rax                                                       ; +0xc6, 0x1004e9fb6\nmov     rax, [rax]                                                     ; +0xc9, 0x1004e9fb9\nmov     rdi, rbx                                                       ; +0xcc, 0x1004e9fbc\nmov     esi, r13d                                                      ; +0xcf, 0x1004e9fbf\ncall    qword ptr [rax+148h]                                           ; +0xd2, 0x1004e9fc2\nmov     rax, [rbx]                                                     ; +0xd8, 0x1004e9fc8\nmov     rdi, rbx                                                       ; +0xdb, 0x1004e9fcb\nmov     esi, r13d                                                      ; +0xde, 0x1004e9fce\ncall    qword ptr [rax+410h]                                           ; +0xe1, 0x1004e9fd1\ninc     r12d                                                           ; +0xe7, 0x1004e9fd7\nmov     rdi, r15                                                       ; +0xea, 0x1004e9fda\ncall    sub_100720070                                                  ; +0xed, 0x1004e9fdd\ncmp     r12d, eax                                                      ; +0xf2, 0x1004e9fe2\njb      short loc_1004E9FA0                                            ; +0xf5, 0x1004e9fe5\njmp     loc_1004E9F50                                                  ; +0xf7, 0x1004e9fe7\nmov     rdi, [rbx+280h]                                                ; +0xfc, 0x1004e9fec\ncall    sub_100720070                                                  ; +0x103, 0x1004e9ff3\ncmp     eax, 2                                                         ; +0x108, 0x1004e9ff8\njnb     short loc_1004EA032                                            ; +0x10b, 0x1004e9ffb\nmov     rdi, [rbx+298h]                                                ; +0x10d, 0x1004e9ffd\nmov     rax, [rdi]                                                     ; +0x114, 0x1004ea004\nxor     esi, esi                                                       ; +0x117, 0x1004ea007\ncall    qword ptr [rax+148h]                                           ; +0x119, 0x1004ea009\nmov     rdi, [rbx+290h]                                                ; +0x11f, 0x1004ea00f\nmov     rax, [rdi]                                                     ; +0x126, 0x1004ea016\nmov     rax, [rax+148h]                                                ; +0x129, 0x1004ea019\nxor     esi, esi                                                       ; +0x130, 0x1004ea020\nadd     rsp, 18h                                                       ; +0x132, 0x1004ea022\npop     rbx                                                            ; +0x136, 0x1004ea026\npop     r12                                                            ; +0x137, 0x1004ea027\npop     r13                                                            ; +0x139, 0x1004ea029\npop     r14                                                            ; +0x13b, 0x1004ea02b\npop     r15                                                            ; +0x13d, 0x1004ea02d\npop     rbp                                                            ; +0x13f, 0x1004ea02f\njmp     rax                                                            ; +0x140, 0x1004ea030\nmov     rdi, rbx                                                       ; +0x142, 0x1004ea032\nadd     rsp, 18h                                                       ; +0x145, 0x1004ea035\npop     rbx                                                            ; +0x149, 0x1004ea039\npop     r12                                                            ; +0x14a, 0x1004ea03a\npop     r13                                                            ; +0x14c, 0x1004ea03c\npop     r14                                                            ; +0x14e, 0x1004ea03e\npop     r15                                                            ; +0x150, 0x1004ea040\npop     rbp                                                            ; +0x152, 0x1004ea042\njmp     BrowseSmartTemplateLayer__updateDots                           ; +0x153, 0x1004ea043", "xrefs": ["BrowseSmartTemplateLayer::init @ 0x1004e94f2", "BrowseSmartTemplateLayer::onClick @ 0x1004ea437", "BrowseSmartKeyLayer::init @ 0x1004eb312"], "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"}