//
// sub_18008B320 from 0x18008b320 to 0x18008b3e3 (195 bytes)
//
// 2 xrefs:
// > ??> @ 0x180103798
// > ??> @ 0x1801b5ae4
//
// 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::CCNodeRGBA *__fastcall sub_18008B320(cocos2d::CCNodeRGBA *this, char a2)
{
cocos2d::CCObject *v5; // rcx
if ( (a2 & 2) != 0 )
{
`eh vector destructor iterator'(this, 0x258u, *((_QWORD *)this - 1), (void (*)(void *))cocos2d::CCSprite::~CCSprite);
if ( (a2 & 1) != 0 )
j_j_j_free_0((char *)this - 8);
return (cocos2d::CCNodeRGBA *)((char *)this - 8);
}
else
{
this->cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable = (cocos2d::CCNodeRGBA_vtbl *)&cocos2d::CCSprite::`vftable'{for `cocos2d::CCNode'};
this->cocos2d::CCRGBAProtocol::__vftable = (cocos2d::CCRGBAProtocol_vtbl *)&cocos2d::CCSprite::`vftable'{for `cocos2d::CCRGBAProtocol'};
*((_QWORD *)this + 43) = &cocos2d::CCSprite::`vftable';
v5 = *((cocos2d::CCObject **)this + 52);
if ( v5 )
cocos2d::CCObject::release(v5);
cocos2d::CCNodeRGBA::~CCNodeRGBA(this);
if ( (a2 & 1) != 0 )
j_j_free_0(this);
return this;
}
}