//
// BoomScrollLayer::instantMoveToPage from 0x1003a6530 to 0x1003a6608 (216 bytes)
//
// 20 xrefs:
// > WorldSelectLayer::goToPage @ 0x1003c2c24
// > ListButtonBar::onLeft @ 0x1003f03a7
// > ListButtonBar::onLeft @ 0x1003f03b6
// > ListButtonBar::onRight @ 0x1003f0443
// > ListButtonBar::onRight @ 0x1003f0452
// > ListButtonBar::goToPage @ 0x1003f04e0
// > ListButtonBar::goToPage @ 0x1003f04ee
// > LevelSelectLayer::init @ 0x100432430
// > LevelSelectLayer::init @ 0x10043246a
// > GauntletSelectLayer::goToPage @ 0x100572f5a
// > EditButtonBar::loadFromItems @ 0x1005e2367
// > EditButtonBar::loadFromItems @ 0x1005e2375
// > EditButtonBar::onLeft @ 0x1005e24d2
// > EditButtonBar::onLeft @ 0x1005e24eb
// > EditButtonBar::onRight @ 0x1005e251e
// > EditButtonBar::onRight @ 0x1005e2537
// > EditButtonBar::goToPage @ 0x1005e2582
// > EditButtonBar::goToPage @ 0x1005e2594
// > SecretRewardsLayer::init @ 0x100631f9c
// > SecretRewardsLayer::init @ 0x100631faa
//
// 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 __fastcall BoomScrollLayer::instantMoveToPage(BoomScrollLayer *a1, int a2)
{
float *v2; // rax
float v3[2]; // [rsp+Ch] [rbp-24h] BYREF
float v4; // [rsp+14h] [rbp-1Ch]
if ( a1->m_looped || a2 >= 0 && (int)sub_100720070(*((_QWORD *)&a1->m_dynamicObjects + 4 * !a1->m_dynamic)) > a2 )
{
cocos2d::CCNode::stopActionByTag(a1->m_extendedLayer, 2);
a1->m_pageMoving = 0;
v4 = (float)-a2;
v2 = (float *)((__int64 (__fastcall *)(BoomScrollLayer *))a1->getContentSize)(a1);
sub_10028CBE0(v3, (float)(*v2 - a1->m_pageOffset) * v4, 0.0);
((void (__fastcall *)(ExtendedLayer *, float *))a1->m_extendedLayer->setPosition)(a1->m_extendedLayer, v3);
a1->m_page = a2;
if ( a1->m_looped )
BoomScrollLayer::repositionPagesLooped(a1);
BoomScrollLayer::moveToPageEnded(a1);
}
}