//
// TableView::reloadData from 0x57b2a8 to 0x57b848 (1440 bytes)
//
// 5 xrefs:
// > BoomListView::setupList @ 0x56bf64
// > BoomListView::setupList @ 0x56bf9c
// > CustomListView::setupList @ 0x60d178
// > MPLobbyLayer::updateComments @ 0x9c9b60
// > ??> @ 0x5f0b8
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void TableView::reloadData(TableView *a1)
{
TableViewDataSource *m_dataSource; // x0
__int64 v3; // x26
signed int v4; // w24
__int64 v5; // x20
TableViewDelegate *m_tableDelegate; // x0
__int64 v7; // x20
float v8; // s10
__int64 v9; // x0
float v10; // s0
float v11; // s1
float y; // s8
TableViewCell *v13; // x0
cocos2d::CCNode *v14; // x21
void (__fastcall *setAnchorPoint)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x23
void (__fastcall *setContentSize)(cocos2d::CCNode *__hidden, const cocos2d::CCSize *); // x23
const cocos2d::CCSize *v17; // x0
void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x23
float v19; // w15
float v20; // w14
float v21; // w13
float v22; // w12
float v23; // w11
float v24; // w10
float v25; // w9
float v26; // w8
float v27; // w7
float v28; // w6
float v29; // w5
float v30; // w4
float v31; // w3
cocos2d::CCArray *m_cellArray; // x0
TableViewDelegate *v33; // x0
TableViewDelegate *v34; // x0
__int64 v35; // x23
const cocos2d::CCSize *v36; // x0
CCContentLayer *m_contentLayer; // x21
signed int v38; // w21
float v39; // s9
__int64 v40; // x0
float v41; // s0
float v42; // s1
__int64 v43; // x27
bool v44; // zf
__int64 (*v45)(void); // x1
float *v46; // x0
float v47; // s0
float v48; // s1
float *v49; // x0
float v50; // s0
float v51; // s1
int v52; // [xsp+A0h] [xbp+A0h]
unsigned int v53; // [xsp+A4h] [xbp+A4h]
signed int v54; // [xsp+A8h] [xbp+A8h]
int v55; // [xsp+ACh] [xbp+ACh]
float v56; // [xsp+B0h] [xbp+B0h]
void (__fastcall *v57)(cocos2d::CCLayerColor *__hidden, const cocos2d::CCSize *); // [xsp+B0h] [xbp+B0h]
float v58; // [xsp+B0h] [xbp+B0h]
cocos2d::CCPoint v59; // [xsp+C8h] [xbp+C8h] BYREF
cocos2d::CCSize v60; // [xsp+D0h] [xbp+D0h] BYREF
cocos2d::CCPoint v61; // [xsp+D8h] [xbp+D8h] BYREF
cocos2d::CCPoint v62; // [xsp+E0h] [xbp+E0h] BYREF
if ( a1->m_tableDelegate )
{
m_dataSource = a1->m_dataSource;
if ( m_dataSource )
{
v52 = m_dataSource->numberOfSectionsInTableView(m_dataSource, a1);
if ( v52 > 0 )
{
v53 = 0;
v3 = 0;
while ( 1 )
{
v55 = a1->m_dataSource->numberOfRowsInSection(a1->m_dataSource, v53, a1);
v54 = cocos2d::CCArray::count(a1->m_cellArray);
if ( v55 > 0 )
break;
LABEL_15:
if ( v52 == ++v53 )
return;
}
v4 = 0;
while ( v54 > v4 )
{
v5 = cocos2d::CCArray::objectAtIndex(a1->m_cellArray, v4);
if ( !v5 )
break;
m_tableDelegate = a1->m_tableDelegate;
if ( m_tableDelegate )
m_tableDelegate->TableViewWillReloadCellForRowAtIndexPath(
m_tableDelegate,
(CCIndexPath *)(v5 + 424),
(TableViewCell *)v5,
a1);
if ( !v4 )
(*(void (__fastcall **)(__int64))(*(_QWORD *)v5 + 192LL))(v5);
v3 = v5;
LABEL_14:
if ( v55 == ++v4 )
goto LABEL_15;
}
v7 = operator new(0x40u);
cocos2d::CCObject::CCObject((cocos2d::CCObject *)v7);
*(_DWORD *)(v7 + 60) = v53;
*(_DWORD *)(v7 + 56) = v4;
*(_QWORD *)v7 = &off_113AA70;
cocos2d::CCObject::autorelease((cocos2d::CCObject *)v7);
v8 = a1->m_tableDelegate->cellHeightForRowAtIndexPath(a1->m_tableDelegate, (CCIndexPath *)v7, a1);
cocos2d::CCPoint::CCPoint(&v59);
if ( v3 )
{
v56 = *(float *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 192LL))(v3);
v9 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 192LL))(v3);
cocos2d::CCPoint::CCPoint(&v62, v56, *(float *)(v9 + 4) - v8);
cocos2d::CCPoint::operator=(&v59, v10, v11);
y = v59.y;
if ( v59.y >= 0.0 )
goto LABEL_19;
}
else
{
y = (float)(a1->m_contentLayer->getContentSize(a1->m_contentLayer)->height - (float)(v8 * (float)v4)) - v8;
v59.y = y;
if ( y >= 0.0 )
{
LABEL_19:
v13 = a1->m_dataSource->cellForRowAtIndexPath(a1->m_dataSource, v7, a1);
v14 = v13;
if ( v13 )
{
setAnchorPoint = v13->setAnchorPoint;
cocos2d::CCPoint::CCPoint(&v62, 0.0, 1.0);
setAnchorPoint(v14, &v62);
setContentSize = v14->setContentSize;
v17 = a1->getContentSize(a1);
cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v62, v17->width, v8);
setContentSize(v14, (const cocos2d::CCSize *)&v62);
setPosition = v14->setPosition;
cocos2d::CCPoint::CCPoint(&v62, 0.0, v59.y);
setPosition(v14, &v62);
v19 = *(float *)(v7 + 12);
v20 = *(float *)(v7 + 16);
v21 = *(float *)(v7 + 20);
v22 = *(float *)(v7 + 24);
v23 = *(float *)(v7 + 28);
v24 = *(float *)(v7 + 32);
v25 = *(float *)(v7 + 36);
v26 = *(float *)(v7 + 40);
v27 = *(float *)(v7 + 44);
v28 = *(float *)(v7 + 48);
v29 = *(float *)(v7 + 52);
v30 = *(float *)(v7 + 56);
v31 = *(float *)(v7 + 60);
m_cellArray = a1->m_cellArray;
v14[1].m_obContentSize.height = *(float *)(v7 + 8);
v14[1].m_sAdditionalTransform.a = v19;
v14[1].m_sAdditionalTransform.b = v20;
v14[1].m_sAdditionalTransform.c = v21;
v14[1].m_sAdditionalTransform.d = v22;
v14[1].m_sAdditionalTransform.tx = v23;
v14[1].m_sAdditionalTransform.ty = v24;
v14[1].m_sTransform.a = v25;
v14[1].m_sTransform.b = v26;
v14[1].m_sTransform.c = v27;
v14[1].m_sTransform.d = v28;
v14[1].m_sTransform.tx = v29;
v14[1].m_sTransform.ty = v30;
v14[1].m_sInverse.a = v31;
cocos2d::CCArray::addObject(m_cellArray, v14);
cocos2d::CCArray::addObject(a1->m_indexPathArray, (cocos2d::CCObject *)v7);
v33 = a1->m_tableDelegate;
if ( v33 )
v33->TableViewWillDisplayCellForRowAtIndexPath(v33, (CCIndexPath *)v7, (TableViewCell *)v14, a1);
a1->m_contentLayer->addChild(a1->m_contentLayer, v14);
v34 = a1->m_tableDelegate;
v3 = (__int64)v14;
if ( v34 )
v34->TableViewDidDisplayCellForRowAtIndexPath(v34, (CCIndexPath *)v7, (TableViewCell *)v14, a1);
}
goto LABEL_14;
}
}
if ( !TableView::isDuplicateIndexPath(a1, (CCIndexPath *)v7) )
{
v35 = 0;
v36 = a1->m_contentLayer->getContentSize(a1->m_contentLayer);
cocos2d::CCSize::CCSize(&v60, v36);
m_contentLayer = a1->m_contentLayer;
v57 = m_contentLayer->setContentSize;
cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v62, v60.width, v60.height - y);
v57(m_contentLayer, (const cocos2d::CCSize *)&v62);
v38 = cocos2d::CCArray::count(a1->m_cellArray) - 1;
if ( v38 >= 0 )
{
do
{
v43 = cocos2d::CCArray::objectAtIndex(a1->m_cellArray, v38);
cocos2d::CCPoint::CCPoint(&v61);
v44 = v38 == (unsigned int)cocos2d::CCArray::count(a1->m_cellArray) - 1;
v45 = *(__int64 (**)(void))(*(_QWORD *)v43 + 192LL);
if ( v44 )
{
v46 = (float *)((__int64 (__fastcall *)(__int64))v45)(v43);
cocos2d::CCPoint::CCPoint(&v62, *v46, (float)(0.0 - y) + 1.0);
cocos2d::CCPoint::operator=(&v61, v47, v48);
v49 = (float *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v43 + 192LL))(v43);
cocos2d::CCPoint::CCPoint(&v62, *v49, v61.y - v8);
cocos2d::CCPoint::operator=(&v59, v50, v51);
}
else
{
v58 = *(float *)v45();
v39 = *(float *)((*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v35 + 192LL))(v35) + 4);
v40 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v35 + 312LL))(v35);
cocos2d::CCPoint::CCPoint(&v62, v58, v39 + *(float *)(v40 + 4));
cocos2d::CCPoint::operator=(&v61, v41, v42);
}
--v38;
v35 = v43;
(*(void (__fastcall **)(__int64, cocos2d::CCPoint *))(*(_QWORD *)v43 + 184LL))(v43, &v61);
}
while ( v38 != -1 );
}
}
goto LABEL_19;
}
}
}
}