//
// MapPackCell::playCompleteEffect from 0x10010f4f4 to 0x10010f704 (528 bytes)
//
// 1 xrefs:
// > MapPackCell::onClaimReward @ 0x10010f4f0
//
// 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 MapPackCell::playCompleteEffect(MapPackCell *a1)
{
__int64 v2; // x0
__int64 *v3; // x0
cocos2d::CCParticleSystemQuad *v4; // x20
FMODAudioEngine *v5; // x20
CCCircleWave *v6; // x20
__int64 v7; // x20
cocos2d::CCNode *v8; // x21
cocos2d::CCScaleTo *v9; // x22
cocos2d::CCScaleTo *v10; // x0
cocos2d::CCAction *v11; // x0
__int64 v12; // x20
__int64 v13; // x0
__int16 v14; // [xsp+1Ch] [xbp-64h] BYREF
char v15; // [xsp+1Eh] [xbp-62h]
void *__p[2]; // [xsp+20h] [xbp-60h] BYREF
char v17; // [xsp+37h] [xbp-49h]
__int64 v18; // [xsp+38h] [xbp-48h] BYREF
v2 = ((__int64 (__fastcall *)(CCMenuItemSpriteExtra *))a1->m_rewardButton->getParent)(a1->m_rewardButton);
v3 = (__int64 *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v2 + 192LL))(v2);
sub_1000229B8(&v18, v3);
v4 = cocos2d::CCParticleSystemQuad::create("starEffect.plist", 0);
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, __int64))v4->setAutoRemoveOnFinish)(v4, 1);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCParticleSystemQuad *, __int64))a1->m_mainLayer->addChild_0)(
a1->m_mainLayer,
v4,
9);
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, __int64 *))v4->setPosition)(v4, &v18);
v5 = FMODAudioEngine::sharedEngine();
sub_100009900(__p, "highscoreGet02.ogg");
FMODAudioEngine::playEffect_1(v5, __p);
if ( v17 < 0 )
operator delete(__p[0]);
v6 = CCCircleWave::create_1(10.0, 90.0, 0.4, 0);
v6->m_color.b = 0;
*(_WORD *)&v6->m_color.r = -1;
((void (__fastcall *)(CCCircleWave *, __int64 *))v6->setPosition)(v6, &v18);
((void (__fastcall *)(cocos2d::CCLayer *, CCCircleWave *, __int64))a1->m_mainLayer->addChild_0)(
a1->m_mainLayer,
v6,
9);
if ( (unsigned int)sub_10024A36C(a1->m_rewardSprites) )
{
v7 = 0;
do
{
v8 = (cocos2d::CCNode *)sub_10024A388(a1->m_rewardSprites, v7);
v9 = cocos2d::CCScaleTo::create_1(0.1, 1.8);
v10 = cocos2d::CCScaleTo::create_1(0.3, 1.0);
cocos2d::CCEaseBounceOut::create(v10);
v11 = (cocos2d::CCAction *)sub_10018A494(v9);
cocos2d::CCNode::runAction(v8, v11);
v7 = (unsigned int)(v7 + 1);
}
while ( (unsigned int)v7 < (unsigned int)sub_10024A36C(a1->m_rewardSprites) );
}
if ( (unsigned int)sub_10024A36C(a1->m_rewardLabels) )
{
v12 = 0;
do
{
v13 = sub_10024A388(a1->m_rewardLabels, v12);
v15 = 50;
v14 = -1;
(*(void (__fastcall **)(__int64, __int16 *))(*(_QWORD *)v13 + 1056LL))(v13, &v14);
v12 = (unsigned int)(v12 + 1);
}
while ( (unsigned int)v12 < (unsigned int)sub_10024A36C(a1->m_rewardLabels) );
}
}