{"type": "func", "start": 4994336, "end": 4994790, "name": "FriendsProfilePage::setupUsersBrowser", "pseudocode": "// \n// FriendsProfilePage::setupUsersBrowser from 0x4c3520 to 0x4c36e6 (454 bytes)\n// \n// 3 xrefs:\n// > FriendsProfilePage::init @ 0x4c3c50\n// > FriendsProfilePage::getUserListFinished @ 0x4c3e84\n// > FriendsProfilePage::forceReloadList @ 0x4c3f52\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 FriendsProfilePage::setupUsersBrowser(FriendsProfilePage *a1, cocos2d::CCArray *a2, UserListType a3)\n{\n  cocos2d::CCDirector *v6; // r0\n  cocos2d::CCTouchDispatcher *v7; // r0\n  cocos2d::CCDirector *v8; // r0\n  CustomListView *v9; // r0\n  GJCommentListLayer *v10; // r0\n  GJCommentListLayer *m_listLayer; // r9\n  void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // r10\n  cocos2d::CCLabelBMFont *m_totalFriends; // r5\n  void (__fastcall *setString)(cocos2d::CCLabelBMFont *__hidden, const unsigned __int8 *); // r6\n  const char *v15; // r0\n  cocos2d::CCString *v16; // r0\n  const char *CString; // r0\n  GameManager *v18; // r0\n  int v19; // r4\n  GameManager *v20; // r0\n  GameManager *v21; // r0\n  GameManager *v22; // r0\n  cocos2d::CCSize v23; // [sp+14h] [bp-14h] BYREF\n  cocos2d::CCPoint v24; // [sp+1Ch] [bp-Ch] BYREF\n\n  if ( a1->m_listLayer )\n  {\n    v6 = cocos2d::CCDirector::sharedDirector();\n    v7 = v6->getTouchDispatcher(v6);\n    cocos2d::CCTouchDispatcher::unregisterForcePrio(v7, a1->m_listLayer);\n    a1->m_listLayer->removeMeAndCleanup(a1->m_listLayer);\n    a1->m_listLayer = nullptr;\n  }\n  v8 = cocos2d::CCDirector::sharedDirector();\n  cocos2d::CCDirector::getWinSize(&v23, v8);\n  if ( a2 )\n    v9 = CustomListView::create(a2, (BoomListType)0, 196.0, 340.0);\n  else\n    v9 = nullptr;\n  v10 = GJCommentListLayer::create(v9, nullptr, (cocos2d::ccColor4B)-12684609, 340.0, 196.0, 0);\n  a1->m_listLayer = v10;\n  a1->m_mainLayer->addChild(a1->m_mainLayer, v10);\n  m_listLayer = a1->m_listLayer;\n  setPosition = m_listLayer->setPosition;\n  cocos2d::CCPoint::CCPoint(\n    &v24,\n    (float)(v23.width - 340.0) * 0.5,\n    (float)((float)((float)(v23.height - 196.0) * 0.5) - 10.0) + 5.0);\n  setPosition(m_listLayer, &v24);\n  if ( !a3 && a2 && cocos2d::CCArray::count(a2) )\n  {\n    m_totalFriends = a1->m_totalFriends;\n    setString = m_totalFriends->setString;\n    v15 = (const char *)cocos2d::CCArray::count(a2);\n    v16 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)\"Total friends: %i\", v15);\n    CString = cocos2d::CCString::getCString(v16);\n    setString(m_totalFriends, (const unsigned __int8 *)CString);\n  }\n  else\n  {\n    a1->m_totalFriends->setString(a1->m_totalFriends, \" \");\n    if ( a3 || !a2 )\n      return;\n  }\n  if ( cocos2d::CCArray::count(a2) )\n  {\n    v18 = GameManager::sharedState();\n    GameManager::reportAchievementWithID(v18, \"geometry.ach.friends01\", 100, 0);\n    v19 = cocos2d::CCArray::count(a2);\n    if ( v19 > 9 )\n    {\n      v20 = GameManager::sharedState();\n      GameManager::reportAchievementWithID(v20, \"geometry.ach.friends02\", 100, 0);\n      if ( v19 > 24 )\n      {\n        v21 = GameManager::sharedState();\n        GameManager::reportAchievementWithID(v21, \"geometry.ach.friends03\", 100, 0);\n        if ( v19 > 49 )\n        {\n          v22 = GameManager::sharedState();\n          GameManager::reportAchievementWithID(v22, \"geometry.ach.friends04\", 100, 0);\n        }\n      }\n    }\n  }\n}", "assembly": "; \n; FriendsProfilePage::setupUsersBrowser from 0x4c3520 to 0x4c36e6 (454 bytes)\n; \n; 3 xrefs:\n; > FriendsProfilePage::init @ 0x4c3c50\n; > FriendsProfilePage::getUserListFinished @ 0x4c3e84\n; > FriendsProfilePage::forceReloadList @ 0x4c3f52\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\nLDR             R3, =(__stack_chk_guard_ptr - 0x4C352A)                ; +0x0, 0x4c3520\nPUSH.W          {R4-R10,LR}                                            ; +0x2, 0x4c3522\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x6, 0x4c3526\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x8, 0x4c3528\nVPUSH           {D8}                                                   ; +0xa, 0x4c352a\nMOV             R8, R2                                                 ; +0xe, 0x4c352e\nLDR             R2, [R3]                                               ; +0x10, 0x4c3530\nMOV             R5, R0                                                 ; +0x12, 0x4c3532\nMOV             R4, R1                                                 ; +0x14, 0x4c3534\nMOV             R7, R3                                                 ; +0x16, 0x4c3536\nSUB             SP, SP, #0x28; float                                   ; +0x18, 0x4c3538\nSTR             R2, [SP,#0x28+var_4]                                   ; +0x1a, 0x4c353a\nLDR.W           R2, [R0,#0x20C]                                        ; +0x1c, 0x4c353c\nCBZ             R2, loc_4C3566                                         ; +0x20, 0x4c3540\nBL              _ZN7cocos2d10CCDirector14sharedDirectorEv; cocos2d::CCDirector::sharedDirector(void) ; +0x22, 0x4c3542\nLDR             R3, [R0]                                               ; +0x26, 0x4c3546\nLDR             R3, [R3,#0x50]                                         ; +0x28, 0x4c3548\nBLX             R3                                                     ; +0x2a, 0x4c354a\nLDR.W           R1, [R5,#0x20C]; cocos2d::CCObject *                   ; +0x2c, 0x4c354c\nBL              _ZN7cocos2d17CCTouchDispatcher19unregisterForcePrioEPNS_8CCObjectE; cocos2d::CCTouchDispatcher::unregisterForcePrio(cocos2d::CCObject *) ; +0x30, 0x4c3550\nLDR.W           R0, [R5,#0x20C]                                        ; +0x34, 0x4c3554\nLDR             R3, [R0]                                               ; +0x38, 0x4c3558\nLDR.W           R3, [R3,#0x104]                                        ; +0x3a, 0x4c355a\nBLX             R3                                                     ; +0x3e, 0x4c355e\nMOVS            R3, #0                                                 ; +0x40, 0x4c3560\nSTR.W           R3, [R5,#0x20C]                                        ; +0x42, 0x4c3562\nBL              _ZN7cocos2d10CCDirector14sharedDirectorEv; cocos2d::CCDirector::sharedDirector(void) ; +0x46, 0x4c3566\nMOV             R1, R0                                                 ; +0x4a, 0x4c356a\nADD             R0, SP, #0x28+var_14; this                             ; +0x4c, 0x4c356c\nBL              _ZN7cocos2d10CCDirector10getWinSizeEv; cocos2d::CCDirector::getWinSize(void) ; +0x4e, 0x4c356e\nMOVS            R1, #0                                                 ; +0x52, 0x4c3572\nCBZ             R4, loc_4C3592                                         ; +0x54, 0x4c3574\nCMP             R8, R1                                                 ; +0x56, 0x4c3576\nMOV             R0, R4                                                 ; +0x58, 0x4c3578\nLDR             R2, =0x43440000                                        ; +0x5a, 0x4c357a\nITE EQ                                                                 ; +0x5c, 0x4c357c\nMOVEQ           R3, #2                                                 ; +0x5e, 0x4c357e\nMOVNE           R3, #0x11                                              ; +0x60, 0x4c3580\nSTMEA.W         SP, {R1,R3}                                            ; +0x62, 0x4c3582\nMOVS            R3, #0                                                 ; +0x66, 0x4c3586\nSTR             R3, [SP,#0x28+var_20]                                  ; +0x68, 0x4c3588\nLDR             R3, =0x43AA0000                                        ; +0x6a, 0x4c358a\nBL              _ZN14CustomListView6createEPN7cocos2d7CCArrayEP21TableViewCellDelegateffi12BoomListTypef; CustomListView::create(cocos2d::CCArray *,TableViewCellDelegate *,float,float,int,BoomListType,float) ; +0x6c, 0x4c358c\nB               loc_4C3594                                             ; +0x70, 0x4c3590\nMOV             R0, R4; int                                            ; +0x72, 0x4c3592\nVLDR            S17, =340.0                                            ; +0x74, 0x4c3594\nMOVS            R3, #0xBF                                              ; +0x78, 0x4c3598\nSTRB.W          R3, [SP,#0x28+var_18]                                  ; +0x7a, 0x4c359a\nMOVS            R3, #0x72 ; 'r'                                        ; +0x7e, 0x4c359e\nSTRB.W          R3, [SP,#0x28+var_18+1]                                ; +0x80, 0x4c35a0\nMOVS            R3, #0x3E ; '>'                                        ; +0x84, 0x4c35a4\nVLDR            S16, =196.0                                            ; +0x86, 0x4c35a6\nMOVS            R1, #0; int                                            ; +0x8a, 0x4c35aa\nSTRB.W          R3, [SP,#0x28+var_18+2]                                ; +0x8c, 0x4c35ac\nMOVS            R3, #0xFF                                              ; +0x90, 0x4c35b0\nSTRB.W          R3, [SP,#0x28+var_18+3]                                ; +0x92, 0x4c35b2\nADD             R6, SP, #0x28+var_C                                    ; +0x96, 0x4c35b6\nLDR             R2, [SP,#0x28+var_18]; int                             ; +0x98, 0x4c35b8\nSTR             R1, [SP,#0x28+var_24]; char                            ; +0x9a, 0x4c35ba\nVMOV            R3, S17; int                                           ; +0x9c, 0x4c35bc\nVSTR            S16, [SP,#0x28+var_28]                                 ; +0xa0, 0x4c35c0\nBL              _ZN18GJCommentListLayer6createEP12BoomListViewPKcN7cocos2d10_ccColor4BEffb; GJCommentListLayer::create(BoomListView *,char const*,cocos2d::_ccColor4B,float,float,bool) ; +0xa4, 0x4c35c4\nMOV             R1, R0                                                 ; +0xa8, 0x4c35c8\nSTR.W           R0, [R5,#0x20C]                                        ; +0xaa, 0x4c35ca\nLDR.W           R0, [R5,#0x1C8]                                        ; +0xae, 0x4c35ce\nLDR             R3, [R0]                                               ; +0xb2, 0x4c35d2\nLDR.W           R3, [R3,#0xDC]                                         ; +0xb4, 0x4c35d4\nBLX             R3                                                     ; +0xb8, 0x4c35d8\nVLDR            S14, [SP,#0x28+var_14]                                 ; +0xba, 0x4c35da\nLDR.W           R9, [R5,#0x20C]                                        ; +0xbe, 0x4c35de\nMOV             R0, R6; this                                           ; +0xc2, 0x4c35e2\nVLDR            S13, [SP,#0x28+var_10]                                 ; +0xc4, 0x4c35e4\nLDR.W           R3, [R9]                                               ; +0xc8, 0x4c35e8\nVMOV.F32        S12, #0.5                                              ; +0xcc, 0x4c35ec\nLDR.W           R10, [R3,#0x5C]                                        ; +0xd0, 0x4c35f0\nVSUB.F32        S14, S14, S17                                          ; +0xd4, 0x4c35f4\nVSUB.F32        S13, S13, S16                                          ; +0xd8, 0x4c35f8\nVMOV.F32        S15, #10.0                                             ; +0xdc, 0x4c35fc\nVMUL.F32        S14, S14, S12                                          ; +0xe0, 0x4c3600\nVNMLS.F32       S15, S13, S12                                          ; +0xe4, 0x4c3604\nVMOV            R1, S14; float                                         ; +0xe8, 0x4c3608\nVMOV.F32        S14, #5.0                                              ; +0xec, 0x4c360c\nVADD.F32        S15, S15, S14                                          ; +0xf0, 0x4c3610\nVMOV            R2, S15; float                                         ; +0xf4, 0x4c3614\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0xf8, 0x4c3618\nMOV             R0, R9                                                 ; +0xfc, 0x4c361c\nMOV             R1, R6                                                 ; +0xfe, 0x4c361e\nBLX             R10                                                    ; +0x100, 0x4c3620\nCMP.W           R8, #0                                                 ; +0x102, 0x4c3622\nBNE             loc_4C3632                                             ; +0x106, 0x4c3626\nCBZ             R4, loc_4C3632                                         ; +0x108, 0x4c3628\nMOV             R0, R4; this                                           ; +0x10a, 0x4c362a\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x10c, 0x4c362c\nCBNZ            R0, loc_4C3656                                         ; +0x110, 0x4c3630\nLDR.W           R0, [R5,#0x208]                                        ; +0x112, 0x4c3632\nLDR             R1, =(asc_943A02 - 0x4C363E); \" \"                      ; +0x116, 0x4c3636\nLDR             R3, [R0]                                               ; +0x118, 0x4c3638\nADD             R1, PC; \" \"                                            ; +0x11a, 0x4c363a\nLDR.W           R3, [R3,#0x1C8]                                        ; +0x11c, 0x4c363c\nBLX             R3                                                     ; +0x120, 0x4c3640\nCMP.W           R8, #0                                                 ; +0x122, 0x4c3642\nBNE             loc_4C36D0                                             ; +0x126, 0x4c3646\nCMP             R4, #0                                                 ; +0x128, 0x4c3648\nBEQ             loc_4C36D0                                             ; +0x12a, 0x4c364a\nMOV             R0, R4; this                                           ; +0x12c, 0x4c364c\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x12e, 0x4c364e\nCBNZ            R0, loc_4C367C                                         ; +0x132, 0x4c3652\nB               loc_4C36D0                                             ; +0x134, 0x4c3654\nLDR.W           R5, [R5,#0x208]                                        ; +0x136, 0x4c3656\nMOV             R0, R4; this                                           ; +0x13a, 0x4c365a\nLDR             R3, [R5]                                               ; +0x13c, 0x4c365c\nLDR.W           R6, [R3,#0x1C8]                                        ; +0x13e, 0x4c365e\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x142, 0x4c3662\nMOV             R1, R0; char *                                         ; +0x146, 0x4c3666\nLDR             R0, =(aTotalFriendsI - 0x4C366E); \"Total friends: %i\"  ; +0x148, 0x4c3668\nADD             R0, PC; \"Total friends: %i\"                            ; +0x14a, 0x4c366a\nBL              _ZN7cocos2d8CCString16createWithFormatEPKcz; cocos2d::CCString::createWithFormat(char const*,...) ; +0x14c, 0x4c366c\nBL              _ZNK7cocos2d8CCString10getCStringEv; cocos2d::CCString::getCString(void) ; +0x150, 0x4c3670\nMOV             R1, R0                                                 ; +0x154, 0x4c3674\nMOV             R0, R5                                                 ; +0x156, 0x4c3676\nBLX             R6                                                     ; +0x158, 0x4c3678\nB               loc_4C364C                                             ; +0x15a, 0x4c367a\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x15c, 0x4c367c\nLDR             R1, =(aGeometryAchFri - 0x4C368A); \"geometry.ach.friends01\" ; +0x160, 0x4c3680\nMOVS            R2, #0x64 ; 'd'; int                                   ; +0x162, 0x4c3682\nMOVS            R3, #0; bool                                           ; +0x164, 0x4c3684\nADD             R1, PC; \"geometry.ach.friends01\"                       ; +0x166, 0x4c3686\nBL              _ZN11GameManager23reportAchievementWithIDEPKcib; GameManager::reportAchievementWithID(char const*,int,bool) ; +0x168, 0x4c3688\nMOV             R0, R4; this                                           ; +0x16c, 0x4c368c\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x16e, 0x4c368e\nCMP             R0, #9                                                 ; +0x172, 0x4c3692\nMOV             R4, R0                                                 ; +0x174, 0x4c3694\nBLE             loc_4C36D0                                             ; +0x176, 0x4c3696\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x178, 0x4c3698\nLDR             R1, =(aGeometryAchFri_0 - 0x4C36A6); \"geometry.ach.friends02\" ; +0x17c, 0x4c369c\nMOVS            R2, #0x64 ; 'd'; int                                   ; +0x17e, 0x4c369e\nMOVS            R3, #0; bool                                           ; +0x180, 0x4c36a0\nADD             R1, PC; \"geometry.ach.friends02\"                       ; +0x182, 0x4c36a2\nBL              _ZN11GameManager23reportAchievementWithIDEPKcib; GameManager::reportAchievementWithID(char const*,int,bool) ; +0x184, 0x4c36a4\nCMP             R4, #0x18                                              ; +0x188, 0x4c36a8\nBLE             loc_4C36D0                                             ; +0x18a, 0x4c36aa\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x18c, 0x4c36ac\nLDR             R1, =(aGeometryAchFri_1 - 0x4C36BA); \"geometry.ach.friends03\" ; +0x190, 0x4c36b0\nMOVS            R2, #0x64 ; 'd'; int                                   ; +0x192, 0x4c36b2\nMOVS            R3, #0; bool                                           ; +0x194, 0x4c36b4\nADD             R1, PC; \"geometry.ach.friends03\"                       ; +0x196, 0x4c36b6\nBL              _ZN11GameManager23reportAchievementWithIDEPKcib; GameManager::reportAchievementWithID(char const*,int,bool) ; +0x198, 0x4c36b8\nCMP             R4, #0x31 ; '1'                                        ; +0x19c, 0x4c36bc\nBLE             loc_4C36D0                                             ; +0x19e, 0x4c36be\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x1a0, 0x4c36c0\nLDR             R1, =(aGeometryAchFri_2 - 0x4C36CE); \"geometry.ach.friends04\" ; +0x1a4, 0x4c36c4\nMOVS            R2, #0x64 ; 'd'; int                                   ; +0x1a6, 0x4c36c6\nMOVS            R3, #0; bool                                           ; +0x1a8, 0x4c36c8\nADD             R1, PC; \"geometry.ach.friends04\"                       ; +0x1aa, 0x4c36ca\nBL              _ZN11GameManager23reportAchievementWithIDEPKcib; GameManager::reportAchievementWithID(char const*,int,bool) ; +0x1ac, 0x4c36cc\nLDR             R2, [SP,#0x28+var_4]                                   ; +0x1b0, 0x4c36d0\nLDR             R3, [R7]                                               ; +0x1b2, 0x4c36d2\nCMP             R2, R3                                                 ; +0x1b4, 0x4c36d4\nBEQ             loc_4C36DC                                             ; +0x1b6, 0x4c36d6\nBLX             __stack_chk_fail                                       ; +0x1b8, 0x4c36d8\nADD             SP, SP, #0x28 ; '('                                    ; +0x1bc, 0x4c36dc\nVPOP            {D8}                                                   ; +0x1be, 0x4c36de\nPOP.W           {R4-R10,PC}                                            ; +0x1c2, 0x4c36e2", "xrefs": ["FriendsProfilePage::init @ 0x4c3c50", "FriendsProfilePage::getUserListFinished @ 0x4c3e84", "FriendsProfilePage::forceReloadList @ 0x4c3f52"], "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"}