//
// BoomScrollLayer::init from 0x3c2318 to 0x3c24fe (486 bytes)
//
// 1 xrefs:
// > BoomScrollLayer::create @ 0x3c263c
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:46:31 +0000
//
ExtendedLayer *__fastcall BoomScrollLayer::init(
unsigned int a1,
cocos2d::CCObject *a2,
int a3,
int a4,
cocos2d::CCObject *a5,
int a6)
{
ExtendedLayer *v10; // r0
ExtendedLayer *v11; // r7
cocos2d::CCLayer *v12; // r0
int v13; // r3
cocos2d::CCDirector *v14; // r0
int v15; // r2
int v16; // r3
float *v17; // r0
cocos2d::CCDirector *v18; // r0
cocos2d::CCDirector *WinSize; // r0
unsigned int v20; // r2
int v21; // r10
cocos2d::CCArray *updated; // r0
int v23; // r3
cocos2d::CCObject *v24; // r0
int v25; // r8
const char *v26; // r1
cocos2d::CCObject *v27; // r9
float v29; // [sp+Ch] [bp-30h]
float v30[2]; // [sp+14h] [bp-28h] BYREF
char v31[4]; // [sp+1Ch] [bp-20h] BYREF
float v32; // [sp+20h] [bp-1Ch]
_DWORD v33[4]; // [sp+24h] [bp-18h] BYREF
v10 = (ExtendedLayer *)cocos2d::CCLayer::init((cocos2d::CCLayer *)a1);
v11 = v10;
if ( v10 )
{
v12 = ExtendedLayer::create(v10);
v13 = *(_DWORD *)a1;
*(_DWORD *)(a1 + 384) = v12;
(*(void (__fastcall **)(unsigned int, cocos2d::CCLayer *))(v13 + 228))(a1, v12);
*(_DWORD *)(a1 + 24) = 4;
v14 = (cocos2d::CCDirector *)(*(int (__fastcall **)(unsigned int, int))(*(_DWORD *)a1 + 500))(a1, 1);
*(_BYTE *)(a1 + 440) = 1;
*(_DWORD *)(a1 + 428) = 1109393408;
*(_DWORD *)(a1 + 432) = 1120403456;
cocos2d::CCDirector::sharedDirector(v14);
cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)v33);
v15 = v33[0];
v16 = *(_DWORD *)a1;
*(_BYTE *)(a1 + 441) = 1;
*(_DWORD *)(a1 + 436) = v15;
v17 = (float *)(*(int (__fastcall **)(unsigned int))(v16 + 164))(a1);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v33, *v17 * 0.5, 60.0);
v18 = (cocos2d::CCDirector *)BoomScrollLayer::setPagesIndicatorPosition(a1, (int)v33);
*(_BYTE *)(a1 + 456) = -106;
*(_BYTE *)(a1 + 457) = -106;
*(_BYTE *)(a1 + 458) = -106;
*(_BYTE *)(a1 + 459) = -1;
*(_BYTE *)(a1 + 452) = -1;
*(_BYTE *)(a1 + 453) = -1;
*(_BYTE *)(a1 + 454) = -1;
*(_BYTE *)(a1 + 455) = -1;
cocos2d::CCDirector::sharedDirector(v18);
WinSize = (cocos2d::CCDirector *)cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)v30);
v29 = v30[0];
cocos2d::CCDirector::sharedDirector(WinSize);
cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)v31);
cocos2d::CCRect::CCRect((cocos2d::CCRect *)v33, 0.0, 0.0, v29, v32);
cocos2d::CCRect::operator=(a1 + 388, v33);
*(_DWORD *)(a1 + 460) = 0;
*(_DWORD *)(a1 + 364) = a2;
*(_DWORD *)(a1 + 404) = 1050253722;
*(float *)(a1 + 464) = (float)a3;
*(_DWORD *)(a1 + 412) = 1053609165;
*(_DWORD *)(a1 + 408) = 1058642330;
cocos2d::CCObject::retain(a2);
v21 = cocos2d::CCSpriteBatchNode::create(
(cocos2d::CCSpriteBatchNode *)"smallDot.png",
(const char *)&dword_1C + 1,
v20);
(*(void (__fastcall **)(unsigned int, int, int))(*(_DWORD *)a1 + 232))(a1, v21, 5);
updated = (cocos2d::CCArray *)BoomScrollLayer::updatePages((cocos2d::CCArray **)a1);
*(_BYTE *)(a1 + 336) = a4;
if ( a4 )
updated = (cocos2d::CCArray *)BoomScrollLayer::repositionPagesLooped((BoomScrollLayer *)a1);
if ( a5 )
updated = (cocos2d::CCArray *)BoomScrollLayer::setupDynamicScrolling(a1, a5, a6, v23);
v24 = (cocos2d::CCObject *)cocos2d::CCArray::create(updated);
v25 = 0;
*(_DWORD *)(a1 + 320) = v24;
cocos2d::CCObject::retain(v24);
while ( v25 < BoomScrollLayer::getTotalPages((cocos2d::CCArray **)a1) )
{
++v25;
v27 = (cocos2d::CCObject *)cocos2d::CCSprite::create((cocos2d::CCSprite *)"smallDot.png", v26);
(*(void (__fastcall **)(int, cocos2d::CCObject *))(*(_DWORD *)v21 + 228))(v21, v27);
cocos2d::CCArray::addObject(*(cocos2d::CCArray **)(a1 + 320), v27);
}
v33[0] = BoomScrollLayer::updateDots;
v33[1] = 0;
cocos2d::CCNode::schedule(a1, BoomScrollLayer::updateDots, 0, 1036831949);
}
return v11;
}