//
// GJEffectManager::getColorSprite from 0xa19648 to 0xa196f0 (168 bytes)
//
// 15 xrefs:
// > GameObject::setupColorSprite @ 0x771e80
// > GameObject::setupColorSprite @ 0x771e94
// > LevelEditorLayer::transferDefaultColors @ 0x78c49c
// > LevelEditorLayer::transferDefaultColors @ 0x78c4c8
// > LevelEditorLayer::transferDefaultColors @ 0x78c4f4
// > LevelEditorLayer::transferDefaultColors @ 0x78c520
// > GJBaseGameLayer::updateColor @ 0x9986b0
// > GJEffectManager::activeColorForIndex @ 0xa1970c
// > GJEffectManager::activeOpacityForIndex @ 0xa19b5c
// > GJEffectManager::calculateLightBGColor @ 0xa19c4c
// > GJEffectManager::calculateLightBGColor @ 0xa19c6c
// > GJEffectManager::setColorAction @ 0xa19d04
// > GJEffectManager::calculateInheritedColor @ 0xa1b270
// > GJEffectManager::processCopyColorPulseActions @ 0xa1bcac
// > ??> @ 0xe1808
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 12:59:36 +0000
//
cocos2d::CCObject *__fastcall GJEffectManager::getColorSprite(GJEffectManager *this, int a2)
{
int v2; // w19
__int64 v3; // x22
__int64 v4; // x20
cocos2d::CCObject *v7; // x20
if ( a2 > 1100 )
{
v3 = 8808;
v2 = 1101;
v4 = *(_QWORD *)(*((_QWORD *)this + 83) + 8808LL);
if ( v4 )
return (cocos2d::CCObject *)v4;
}
else
{
if ( a2 < 0 )
v2 = 0;
else
v2 = a2;
v3 = 8LL * v2;
v4 = *(_QWORD *)(*((_QWORD *)this + 83) + v3);
if ( v4 )
return (cocos2d::CCObject *)v4;
}
v7 = (cocos2d::CCObject *)ColorActionSprite::create(this);
*((_DWORD *)v7 + 82) = v2;
(*(void (__fastcall **)(GJEffectManager *, cocos2d::CCObject *))(*(_QWORD *)this + 456LL))(this, v7);
*(_QWORD *)(*((_QWORD *)this + 83) + v3) = v7;
cocos2d::CCDictionary::setObject(*((cocos2d::CCDictionary **)this + 42), v7, v2);
return v7;
}