{"type": "func", "start": 7871568, "end": 7871974, "name": "EditorSoundBrowserLayer::layoutCells", "pseudocode": "// \n// EditorSoundBrowserLayer::layoutCells from 0x781c50 to 0x781de6 (406 bytes)\n// \n// 4 xrefs:\n// > EditorSoundBrowserLayer::loadEditorSoundsFinished @ 0x7820d8\n// > EditorSoundBrowserLayer::loadEditorSoundsFailed @ 0x782142\n// > EditorSoundBrowserLayer::loadCurrentPage @ 0x782304\n// > EditorSoundBrowserLayer::loadCurrentPage @ 0x782388\n// \n// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:59:29 +0000\n// \n\nint __fastcall EditorSoundBrowserLayer::layoutCells(\n        EditorSoundBrowserLayer *this,\n        cocos2d::CCArray *a2,\n        cocos2d::CCLabelBMFont *a3)\n{\n  cocos2d::CCObject *v6; // r0\n  const char *v7; // r2\n  int v8; // r5\n  void (__fastcall *v9)(int, _BYTE *); // r2\n  void (__fastcall *v10)(int, _BYTE *); // r8\n  int v12; // r3\n  cocos2d::CCLayer *v13; // r0\n  cocos2d::CCLayerColor *v14; // r0\n  cocos2d::CCDirector *v15; // r0\n  int v16; // r4\n  int (__fastcall *v17)(int, _BYTE *); // r5\n  float v18; // [sp+14h] [bp-8h] BYREF\n  float v19; // [sp+18h] [bp-4h]\n  _BYTE v20[8]; // [sp+1Ch] [bp+0h] BYREF\n\n  v6 = EditorSoundBrowserLayer::clearCells(this);\n  *((_DWORD *)this + 190) = a2;\n  if ( a2 && (cocos2d::CCObject::retain(a2), (v6 = (cocos2d::CCObject *)cocos2d::CCArray::count(a2)) != nullptr) )\n  {\n    if ( *((_DWORD *)this + 182) == 1 )\n      v12 = 35;\n    else\n      v12 = 34;\n    v13 = CustomListView::create(a2, (int)this + 720, 1127481344, 1135214592, 0, v12, *((_DWORD *)this + 203));\n    v14 = GJCommentListLayer::create((int)v13, (int)&unk_B6B226, -14201459, 340.0, 180.0, 0);\n    *((_DWORD *)this + 184) = v14;\n    v15 = (cocos2d::CCDirector *)(*(int (__fastcall **)(_DWORD, cocos2d::CCLayerColor *, int))(**((_DWORD **)this + 115)\n                                                                                             + 232))(\n                                   *((_DWORD *)this + 115),\n                                   v14,\n                                   5);\n    cocos2d::CCDirector::sharedDirector(v15);\n    cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v18);\n    v16 = *((_DWORD *)this + 184);\n    v17 = *(int (__fastcall **)(int, _BYTE *))(*(_DWORD *)v16 + 92);\n    cocos2d::CCPoint::CCPoint(\n      (cocos2d::CCPoint *)v20,\n      (float)(v18 - 340.0) * 0.5,\n      (float)((float)(v19 - 180.0) * 0.5) - 30.0);\n    return v17(v16, v20);\n  }\n  else\n  {\n    cocos2d::CCDirector::sharedDirector(v6);\n    cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v18);\n    v8 = cocos2d::CCLabelBMFont::create(a3, \"bigFont.fnt\", v7);\n    (*(void (__fastcall **)(int, int))(*(_DWORD *)v8 + 80))(v8, 1058642330);\n    v9 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v8 + 536);\n    v20[0] = -56;\n    v20[1] = -56;\n    v20[2] = -56;\n    v9(v8, v20);\n    v10 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v8 + 92);\n    cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v20, v18 * 0.5, (float)(v19 * 0.5) - 10.0);\n    v10(v8, v20);\n    (*(void (__fastcall **)(int, int))(*(_DWORD *)v8 + 36))(v8, 9999);\n    return (*(int (__fastcall **)(_DWORD, int, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v8, 5);\n  }\n}", "assembly": "; \n; EditorSoundBrowserLayer::layoutCells from 0x781c50 to 0x781de6 (406 bytes)\n; \n; 4 xrefs:\n; > EditorSoundBrowserLayer::loadEditorSoundsFinished @ 0x7820d8\n; > EditorSoundBrowserLayer::loadEditorSoundsFailed @ 0x782142\n; > EditorSoundBrowserLayer::loadCurrentPage @ 0x782304\n; > EditorSoundBrowserLayer::loadCurrentPage @ 0x782388\n; \n; This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:59:29 +0000\n; \nPUSH.W          {R4-R9,LR}                                             ; +0x0, 0x781c50\nMOV             R4, R0                                                 ; +0x4, 0x781c54\nVPUSH           {D8-D9}                                                ; +0x6, 0x781c56\nMOV             R5, R1                                                 ; +0xa, 0x781c5a\nLDR             R6, =(__stack_chk_guard_ptr - 0x781C64)                ; +0xc, 0x781c5c\nMOV             R9, R2                                                 ; +0xe, 0x781c5e\nADD             R6, PC; __stack_chk_guard_ptr                          ; +0x10, 0x781c60\nLDR             R6, [R6]; __stack_chk_guard                            ; +0x12, 0x781c62\nVMOV.F32        S16, #0.5                                              ; +0x14, 0x781c64\nSUB             SP, SP, #0x2C                                          ; +0x18, 0x781c68\nLDR             R3, [R6]                                               ; +0x1a, 0x781c6a\nADD.W           R8, SP, #0x2C+var_18                                   ; +0x1c, 0x781c6c\nADD             R7, SP, #0x1C                                          ; +0x20, 0x781c70\nSTR             R3, [SP,#0x2C+var_8]                                   ; +0x22, 0x781c72\nBL              _ZN23EditorSoundBrowserLayer10clearCellsEv; EditorSoundBrowserLayer::clearCells(void) ; +0x24, 0x781c74\nSTR.W           R5, [R4,#0x2F8]                                        ; +0x28, 0x781c78\nCBZ             R5, loc_781C8E                                         ; +0x2c, 0x781c7c\nMOV             R0, R5; this                                           ; +0x2e, 0x781c7e\nBL              _ZN7cocos2d8CCObject6retainEv; cocos2d::CCObject::retain(void) ; +0x30, 0x781c80\nMOV             R0, R5; this                                           ; +0x34, 0x781c84\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x36, 0x781c86\nCMP             R0, #0                                                 ; +0x3a, 0x781c8a\nBNE             loc_781D14                                             ; +0x3c, 0x781c8c\nBL              _ZN7cocos2d10CCDirector14sharedDirectorEv; cocos2d::CCDirector::sharedDirector(void) ; +0x3e, 0x781c8e\nMOV             R1, R0                                                 ; +0x42, 0x781c92\nMOV             R0, R8; this                                           ; +0x44, 0x781c94\nBL              _ZN7cocos2d10CCDirector10getWinSizeEv; cocos2d::CCDirector::getWinSize(void) ; +0x46, 0x781c96\nLDR             R1, =(aBigfontFnt - 0x781CA2); \"bigFont.fnt\"           ; +0x4a, 0x781c9a\nMOV             R0, R9; this                                           ; +0x4c, 0x781c9c\nADD             R1, PC; \"bigFont.fnt\"                                  ; +0x4e, 0x781c9e\nBL              _ZN7cocos2d13CCLabelBMFont6createEPKcS2_; cocos2d::CCLabelBMFont::create(char const*,char const*) ; +0x50, 0x781ca0\nLDR             R1, =0x3F19999A                                        ; +0x54, 0x781ca4\nLDR             R3, [R0]                                               ; +0x56, 0x781ca6\nMOV             R5, R0                                                 ; +0x58, 0x781ca8\nLDR             R3, [R3,#0x50]                                         ; +0x5a, 0x781caa\nBLX             R3                                                     ; +0x5c, 0x781cac\nLDR             R3, [R5]                                               ; +0x5e, 0x781cae\nMOV             R0, R5                                                 ; +0x60, 0x781cb0\nMOV             R1, R7                                                 ; +0x62, 0x781cb2\nLDR.W           R2, [R3,#0x218]                                        ; +0x64, 0x781cb4\nMOVS            R3, #0xC8                                              ; +0x68, 0x781cb8\nSTRB.W          R3, [SP,#0x2C+var_10]                                  ; +0x6a, 0x781cba\nSTRB.W          R3, [SP,#0x2C+var_F]                                   ; +0x6e, 0x781cbe\nSTRB.W          R3, [SP,#0x2C+var_E]                                   ; +0x72, 0x781cc2\nBLX             R2                                                     ; +0x76, 0x781cc6\nVLDR            S15, [SP,#0x2C+var_18]                                 ; +0x78, 0x781cc8\nLDR             R3, [R5]                                               ; +0x7c, 0x781ccc\nMOV             R0, R7; this                                           ; +0x7e, 0x781cce\nVLDR            S14, [SP,#0x2C+var_14]                                 ; +0x80, 0x781cd0\nLDR.W           R8, [R3,#0x5C]                                         ; +0x84, 0x781cd4\nVMUL.F32        S15, S15, S16                                          ; +0x88, 0x781cd8\nVMOV            R1, S15; float                                         ; +0x8c, 0x781cdc\nVMOV.F32        S15, #10.0                                             ; +0x90, 0x781ce0\nVNMLS.F32       S15, S14, S16                                          ; +0x94, 0x781ce4\nVMOV            R2, S15; float                                         ; +0x98, 0x781ce8\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0x9c, 0x781cec\nMOV             R0, R5                                                 ; +0xa0, 0x781cf0\nMOV             R1, R7                                                 ; +0xa2, 0x781cf2\nBLX             R8                                                     ; +0xa4, 0x781cf4\nLDR             R3, [R5]                                               ; +0xa6, 0x781cf6\nMOV             R0, R5                                                 ; +0xa8, 0x781cf8\nMOVW            R1, #0x270F                                            ; +0xaa, 0x781cfa\nLDR             R3, [R3,#0x24]                                         ; +0xae, 0x781cfe\nBLX             R3                                                     ; +0xb0, 0x781d00\nLDR.W           R0, [R4,#0x1CC]                                        ; +0xb2, 0x781d02\nMOV             R1, R5                                                 ; +0xb6, 0x781d06\nMOVS            R2, #5                                                 ; +0xb8, 0x781d08\nLDR             R3, [R0]                                               ; +0xba, 0x781d0a\nLDR.W           R3, [R3,#0xE8]                                         ; +0xbc, 0x781d0c\nBLX             R3                                                     ; +0xc0, 0x781d10\nB               loc_781DD0                                             ; +0xc2, 0x781d12\nLDR.W           R3, [R4,#0x2D8]                                        ; +0xc4, 0x781d14\nMOV.W           R9, #0                                                 ; +0xc8, 0x781d18\nVLDR            S17, =180.0                                            ; +0xcc, 0x781d1c\nADD.W           R1, R4, #0x2D0                                         ; +0xd0, 0x781d20\nCMP             R3, #1                                                 ; +0xd4, 0x781d24\nSTR.W           R9, [SP,#0x2C+var_2C]; float                           ; +0xd6, 0x781d26\nMOV             R0, R5                                                 ; +0xda, 0x781d2a\nVLDR            S18, =340.0                                            ; +0xdc, 0x781d2c\nITE EQ                                                                 ; +0xe0, 0x781d30\nMOVEQ           R3, #0x23 ; '#'                                        ; +0xe2, 0x781d32\nMOVNE           R3, #0x22 ; '\"'                                        ; +0xe4, 0x781d34\nSTR             R3, [SP,#0x2C+var_28]                                  ; +0xe6, 0x781d36\nLDR.W           R3, [R4,#0x32C]                                        ; +0xe8, 0x781d38\nVMOV            R2, S17                                                ; +0xec, 0x781d3c\nSTR             R3, [SP,#0x2C+var_24]                                  ; +0xf0, 0x781d40\nVMOV            R3, S18                                                ; +0xf2, 0x781d42\nBL              _ZN14CustomListView6createEPN7cocos2d7CCArrayEP21TableViewCellDelegateffi12BoomListTypef; CustomListView::create(cocos2d::CCArray *,TableViewCellDelegate *,float,float,int,BoomListType,float) ; +0xf6, 0x781d46\nLDR             R1, =(unk_B6B226 - 0x781D68)                           ; +0xfa, 0x781d4a\nMOVS            R3, #0x8D                                              ; +0xfc, 0x781d4c\nSTRB.W          R3, [SP,#0x2C+var_1C]                                  ; +0xfe, 0x781d4e\nMOVS            R3, #0x4D ; 'M'                                        ; +0x102, 0x781d52\nSTRB.W          R3, [SP,#0x2C+var_1C+1]                                ; +0x104, 0x781d54\nMOVS            R3, #0x27 ; '''                                        ; +0x108, 0x781d58\nSTRB.W          R3, [SP,#0x2C+var_1C+2]                                ; +0x10a, 0x781d5a\nMOVS            R3, #0xFF                                              ; +0x10e, 0x781d5e\nSTRB.W          R3, [SP,#0x2C+var_1C+3]                                ; +0x110, 0x781d60\nADD             R1, PC; unk_B6B226 ; int                               ; +0x114, 0x781d64\nLDR             R2, [SP,#0x2C+var_1C]; int                             ; +0x116, 0x781d66\nVMOV            R3, S18; int                                           ; +0x118, 0x781d68\nVSTR            S17, [SP,#0x2C+var_2C]                                 ; +0x11c, 0x781d6c\nSTR.W           R9, [SP,#0x2C+var_28]; char                            ; +0x120, 0x781d70\nBL              _ZN18GJCommentListLayer6createEP12BoomListViewPKcN7cocos2d10_ccColor4BEffb; GJCommentListLayer::create(BoomListView *,char const*,cocos2d::_ccColor4B,float,float,bool) ; +0x124, 0x781d74\nMOVS            R2, #5                                                 ; +0x128, 0x781d78\nSTR.W           R0, [R4,#0x2E0]                                        ; +0x12a, 0x781d7a\nMOV             R1, R0                                                 ; +0x12e, 0x781d7e\nLDR.W           R0, [R4,#0x1CC]                                        ; +0x130, 0x781d80\nLDR             R3, [R0]                                               ; +0x134, 0x781d84\nLDR.W           R3, [R3,#0xE8]                                         ; +0x136, 0x781d86\nBLX             R3                                                     ; +0x13a, 0x781d8a\nBL              _ZN7cocos2d10CCDirector14sharedDirectorEv; cocos2d::CCDirector::sharedDirector(void) ; +0x13c, 0x781d8c\nMOV             R1, R0                                                 ; +0x140, 0x781d90\nMOV             R0, R8; this                                           ; +0x142, 0x781d92\nBL              _ZN7cocos2d10CCDirector10getWinSizeEv; cocos2d::CCDirector::getWinSize(void) ; +0x144, 0x781d94\nVLDR            S14, [SP,#0x2C+var_18]                                 ; +0x148, 0x781d98\nLDR.W           R4, [R4,#0x2E0]                                        ; +0x14c, 0x781d9c\nMOV             R0, R7; this                                           ; +0x150, 0x781da0\nVLDR            S15, [SP,#0x2C+var_14]                                 ; +0x152, 0x781da2\nLDR             R3, [R4]                                               ; +0x156, 0x781da6\nVSUB.F32        S14, S14, S18                                          ; +0x158, 0x781da8\nLDR             R5, [R3,#0x5C]                                         ; +0x15c, 0x781dac\nVMUL.F32        S14, S14, S16                                          ; +0x15e, 0x781dae\nVSUB.F32        S15, S15, S17                                          ; +0x162, 0x781db2\nVMOV            R1, S14; float                                         ; +0x166, 0x781db6\nVMOV.F32        S14, #30.0                                             ; +0x16a, 0x781dba\nVNMLS.F32       S14, S15, S16                                          ; +0x16e, 0x781dbe\nVMOV            R2, S14; float                                         ; +0x172, 0x781dc2\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0x176, 0x781dc6\nMOV             R0, R4                                                 ; +0x17a, 0x781dca\nMOV             R1, R7                                                 ; +0x17c, 0x781dcc\nBLX             R5                                                     ; +0x17e, 0x781dce\nLDR             R2, [SP,#0x2C+var_8]                                   ; +0x180, 0x781dd0\nLDR             R3, [R6]                                               ; +0x182, 0x781dd2\nCMP             R2, R3                                                 ; +0x184, 0x781dd4\nBEQ             loc_781DDC                                             ; +0x186, 0x781dd6\nBLX             __stack_chk_fail                                       ; +0x188, 0x781dd8\nADD             SP, SP, #0x2C ; ','                                    ; +0x18c, 0x781ddc\nVPOP            {D8-D9}                                                ; +0x18e, 0x781dde\nPOP.W           {R4-R9,PC}                                             ; +0x192, 0x781de2", "xrefs": ["EditorSoundBrowserLayer::loadEditorSoundsFinished @ 0x7820d8", "EditorSoundBrowserLayer::loadEditorSoundsFailed @ 0x782142", "EditorSoundBrowserLayer::loadCurrentPage @ 0x782304", "EditorSoundBrowserLayer::loadCurrentPage @ 0x782388"], "is_objc": false, "is_32_bit": true, "is_64_bit": false, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}