{"type": "func", "start": 4299302192, "end": 4299302348, "name": "AchievementsLayer::setupPageInfo", "pseudocode": "// \n// AchievementsLayer::setupPageInfo from 0x100422530 to 0x1004225cc (156 bytes)\n// \n// 1 xrefs:\n// > AchievementsLayer::loadPage @ 0x100422390\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 AchievementsLayer::setupPageInfo(AchievementsLayer *a1, int a2, int a3, int a4)\n{\n  int v8; // w8\n  int v9; // w19\n  int v10; // w20\n  cocos2d::CCString *v11; // x0\n  const char *CString; // x1\n\n  ((void (__fastcall *)(CCMenuItemSpriteExtra *, bool))a1->m_prevPageButton->setVisible)(a1->m_prevPageButton, a3 != 0);\n  v8 = a4 + a3;\n  v9 = a3 + 1;\n  if ( v8 >= a2 )\n    v10 = a2;\n  else\n    v10 = v8;\n  ((void (__fastcall *)(CCMenuItemSpriteExtra *, bool))a1->m_nextPageButton->setVisible)(a1->m_nextPageButton, v8 < a2);\n  v11 = (cocos2d::CCString *)sub_100268F4C(\"%i to %i of %i\", v9, v10, a2);\n  CString = cocos2d::CCString::getCString(v11);\n  ((void (__fastcall *)(cocos2d::CCLabelBMFont *, const char *))a1->m_pageLabel->setString)(a1->m_pageLabel, CString);\n}", "assembly": "; \n; AchievementsLayer::setupPageInfo from 0x100422530 to 0x1004225cc (156 bytes)\n; \n; 1 xrefs:\n; > AchievementsLayer::loadPage @ 0x100422390\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\nSUB             SP, SP, #0x50                                          ; +0x0, 0x100422530\nSTP             X22, X21, [SP,#0x40+var_20]                            ; +0x4, 0x100422534\nSTP             X20, X19, [SP,#0x40+var_10]                            ; +0x8, 0x100422538\nSTP             X29, X30, [SP,#0x40+var_s0]                            ; +0xc, 0x10042253c\nADD             X29, SP, #0x40                                         ; +0x10, 0x100422540\nMOV             X19, X3                                                ; +0x14, 0x100422544\nMOV             X20, X2                                                ; +0x18, 0x100422548\nMOV             X21, X1                                                ; +0x1c, 0x10042254c\nMOV             X22, X0                                                ; +0x20, 0x100422550\nCMP             W2, #0                                                 ; +0x24, 0x100422554\nCSET            W1, NE                                                 ; +0x28, 0x100422558\nLDR             X0, [X0,#0x268]                                        ; +0x2c, 0x10042255c\nLDR             X8, [X0]                                               ; +0x30, 0x100422560\nLDR             X8, [X8,#0x148]                                        ; +0x34, 0x100422564\nBLR             X8                                                     ; +0x38, 0x100422568\nADD             W8, W19, W20                                           ; +0x3c, 0x10042256c\nCMP             W8, W21                                                ; +0x40, 0x100422570\nCSET            W1, LT                                                 ; +0x44, 0x100422574\nLDR             X0, [X22,#0x260]                                       ; +0x48, 0x100422578\nLDR             X9, [X0]                                               ; +0x4c, 0x10042257c\nLDR             X9, [X9,#0x148]                                        ; +0x50, 0x100422580\nADD             W19, W20, #1                                           ; +0x54, 0x100422584\nCSEL            W20, W8, W21, LT                                       ; +0x58, 0x100422588\nBLR             X9                                                     ; +0x5c, 0x10042258c\nSTP             X20, X21, [SP,#0x40+var_38]                            ; +0x60, 0x100422590\nSTR             X19, [SP,#0x40+var_40]                                 ; +0x64, 0x100422594\nADRL            X0, aIToIOfI; \"%i to %i of %i\"                         ; +0x68, 0x100422598\nBL              sub_100268F4C                                          ; +0x70, 0x1004225a0\nBL              cocos2d__CCString__getCString                          ; +0x74, 0x1004225a4\nMOV             X1, X0                                                 ; +0x78, 0x1004225a8\nLDR             X0, [X22,#0x270]                                       ; +0x7c, 0x1004225ac\nLDR             X8, [X0]                                               ; +0x80, 0x1004225b0\nLDR             X2, [X8,#0x390]                                        ; +0x84, 0x1004225b4\nLDP             X29, X30, [SP,#0x40+var_s0]                            ; +0x88, 0x1004225b8\nLDP             X20, X19, [SP,#0x40+var_10]                            ; +0x8c, 0x1004225bc\nLDP             X22, X21, [SP,#0x40+var_20]                            ; +0x90, 0x1004225c0\nADD             SP, SP, #0x50 ; 'P'                                    ; +0x94, 0x1004225c4\nBR              X2                                                     ; +0x98, 0x1004225c8", "xrefs": ["AchievementsLayer::loadPage @ 0x100422390"], "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"}