//
// EnhancedGameObject::updateUserCoin from 0x1005c1a80 to 0x1005c1b90 (272 bytes)
//
// 2 xrefs:
// > PlayLayer::createObjectsFromSetupFinished @ 0x1000b6a70
// > GameObject::objectFromVector @ 0x1005c12a8
//
// 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 EnhancedGameObject::updateUserCoin(EnhancedGameObject *a1)
{
GameManager *v1; // rax
bool hasUniqueCoin; // al
cocos2d::CCParticleSystemQuad *v3; // rax
cocos2d::CCParticleSystemQuad *v4; // r14
_OWORD v5[2]; // [rsp-28h] [rbp-28h] BYREF
if ( !a1->m_editorEnabled )
{
v1 = GameManager::sharedState();
hasUniqueCoin = GJBaseGameLayer::hasUniqueCoin(v1->m_playLayer, (EffectGameObject *)a1);
a1->m_hasUniqueCoin = hasUniqueCoin;
if ( !hasUniqueCoin )
{
v3 = GameObject::createAndAddParticle(a1, a1->m_objectType, "coinEffect.plist", 0, kCCPositionTypeGrouped);
if ( v3 )
{
if ( a1->m_objectID != 142 )
{
v4 = v3;
v5[0] = _mm_movelh_ps(
(__m128)xmmword_1008154E0,
_mm_insert_ps(
(__m128)xmmword_1008165D0,
(__m128)*(unsigned int *)(((__int64 (__fastcall *)(cocos2d::CCParticleSystemQuad *))v3->getStartColor)(v3)
+ 12),
16));
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, _OWORD *))v4->setStartColor)(v4, v5);
v5[0] = _mm_movelh_ps(
(__m128)xmmword_100816970,
_mm_insert_ps(
(__m128)xmmword_1008182B0,
(__m128)*(unsigned int *)(((__int64 (__fastcall *)(cocos2d::CCParticleSystemQuad *))v4->getEndColor)(v4)
+ 12),
16));
((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, _OWORD *))v4->setEndColor)(v4, v5);
}
}
sub_10028CBE0((float *)v5, 0.0, -19.0);
sub_10028CC90(&a1->m_particleOffset, (double *)v5);
}
}
}