//
// GameToolbox::particleFromString from 0x1004f5f20 to 0x1004f600c (236 bytes)
//
// 19 xrefs:
// > ParticleGameObject::updateParticle @ 0x1001b23d1
// > LevelAreaLayer::init @ 0x100278383
// > GJDifficultySprite::updateFeatureState @ 0x1002b6f99
// > GJPathPage::playUnlockAnimation @ 0x100301229
// > GJPathPage::unlockAnimationStep2 @ 0x100301c63
// > GJPathPage::unlockAnimationStep3 @ 0x1003022ec
// > GJPathPage::unlockAnimationStep3 @ 0x1003024f8
// > LevelPage::updateDynamicPage @ 0x100433094
// > LevelPage::updateDynamicPage @ 0x100433168
// > LevelPage::updateDynamicPage @ 0x10043324e
// > CreateParticlePopup::init @ 0x10046ee8e
// > CreateParticlePopup::init @ 0x10046eeab
// > CreateParticlePopup::init @ 0x100472adb
// > CreateParticlePopup::init @ 0x100472c1d
// > SecretLayer5::onSubmit @ 0x10047b627
// > GauntletSelectLayer::playUnlockAnimation @ 0x1005733d3
// > GauntletSelectLayer::unlockAnimationStep2 @ 0x1005739be
// > GauntletSelectLayer::unlockAnimationStep3 @ 0x100573c9e
// > GauntletSelectLayer::unlockAnimationStep3 @ 0x100573e41
//
// 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
//
cocos2d::CCParticleSystemQuad *__fastcall GameToolbox::particleFromString(
unsigned __int8 *a1,
cocos2d::CCParticleSystemQuad *a2,
bool a3)
{
cocos2d::CCParticleSystemQuad *v4; // rbx
unsigned int v5; // eax
cocos2d::ParticleStruct v7; // [rsp+0h] [rbp-130h] BYREF
v4 = a2;
v5 = *a1;
if ( (v5 & 1) != 0 )
{
if ( !*((_QWORD *)a1 + 1) )
return v4;
}
else if ( !(v5 >> 1) )
{
return v4;
}
memset(&v7, 0, 221);
memset(&v7.frictionPos, 0, 21);
memset(&v7.frictionSize, 0, 40);
GameToolbox::particleStringToStruct(a1, (__int64)&v7);
v4 = GameToolbox::particleFromStruct(&v7, a2, a3);
if ( (v7.sFrame.m_data.m_short.sizex2 & 1) != 0 )
operator delete(v7.sFrame.m_data.m_long.longStorage);
return v4;
}