//
// EndLevelLayer::coinEnterFinished from 0x1004c3560 to 0x1004c3734 (468 bytes)
//
// 1 xrefs:
// > EndLevelLayer::coinEnterFinishedO @ 0x1004c354f
//
// 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 EndLevelLayer::coinEnterFinished(EndLevelLayer *a1, cocos2d::CCPoint a2)
{
unsigned __int64 *v2; // rsi
cocos2d::CCParticleSystemQuad *v3; // r14
__m128 v4; // xmm0
unsigned int v5; // xmm1_4
FMODAudioEngine *v6; // rax
CCCircleWave *v7; // r14
int v8; // eax
__m128 inserted; // [rsp+10h] [rbp-60h]
__m128 v10; // [rsp+28h] [rbp-48h] BYREF
double v11; // [rsp+38h] [rbp-38h] BYREF
__int128 v12[3]; // [rsp+40h] [rbp-30h] BYREF
sub_10028CBE0(v10.f32, 0.0, 0.0);
sub_10028CCE0(&v11, v2, (unsigned __int64 *)&v10);
v3 = cocos2d::CCParticleSystemQuad::create("starEffect.plist", 0);
if ( a1->m_notLocal )
{
v4 = (__m128)0x3F800000u;
v5 = 1065353216;
if ( !a1->m_coinsVerified )
{
v5 = 1060089776;
v4 = (__m128)0x3E969697u;
}
inserted = _mm_insert_ps((__m128)xmmword_1008165D0, (__m128)v5, 16);
v10 = _mm_movelh_ps(
inserted,
_mm_insert_ps(
v4,
(__m128)*(unsigned int *)(((__int64 (__fastcall *)(cocos2d::CCParticleSystemQuad *))v3->getStartColor)(v3)
+ 12),
16));
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, __m128 *))v3->setStartColor)(v3, &v10);
v10 = _mm_insert_ps(inserted, (__m128)v4.u32[0], 40);
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, __m128 *))v3->setEndColor)(v3, &v10);
}
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, __int64))v3->setAutoRemoveOnFinish)(v3, 1);
((void (__fastcall *)(cocos2d::CCLayer *, cocos2d::CCParticleSystemQuad *, __int64))a1->m_mainLayer->addChild_0)(
a1->m_mainLayer,
v3,
9);
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, double *))v3->setPosition)(v3, &v11);
v6 = FMODAudioEngine::sharedEngine();
strcpy((char *)v12, "$highscoreGet02.ogg");
FMODAudioEngine::playEffect_1((__int64)v6, v12, 1.674390687123889e243);
if ( (v12[0] & 1) != 0 )
operator delete(*(void **)&v12[1]);
v7 = CCCircleWave::create_1(10.0, 90.0, 0.40000001, 0);
v8 = 0xFFFF;
if ( a1->m_notLocal )
v8 = a1->m_coinsVerified ? -1 : 0x4BAFFF;
*(_WORD *)&v7->m_color.r = v8;
v7->m_color.b = BYTE2(v8);
((void (__fastcall *)(CCCircleWave *, double *))v7->setPosition)(v7, &v11);
((void (__fastcall *)(cocos2d::CCLayer *, CCCircleWave *, __int64))a1->m_mainLayer->addChild_0)(
a1->m_mainLayer,
v7,
9);
}