//
// cocos2d::CCSprite::setOpacity from 0xd88300 to 0xd88388 (136 bytes)
//
// 31 xrefs:
// > CCAnimatedSprite::setOpacity @ 0x68d714
// > CCCountdown::setOpacity @ 0x68fccc
// > CCPartAnimSprite::setOpacity @ 0x6926a0
// > MultilineBitmapFont::setOpacity @ 0x6acfd8
// > TextArea::setOpacity @ 0x6b3584
// > CCSpriteCOpacity::setOpacity @ 0x6c83fc
// > GameObject::setOpacity @ 0x76ecd8
// > GJItemIcon::setOpacity @ 0x8c3190
// > GJChestSprite::setOpacity @ 0xa8a13c
// > `non-virtual thunk to'cocos2d::CCSprite::setOpacity @ 0xd8838c
// > ??> @ 0xbc8c0
// > ??> @ 0x1413970
// > ??> @ 0x1417af0
// > ??> @ 0x141b410
// > ??> @ 0x1421af0
// > ??> @ 0x1423a60
// > ??> @ 0x1424010
// > ??> @ 0x14245e0
// > ??> @ 0x1428fc0
// > ??> @ 0x1433e30
// > ??> @ 0x143a3a0
// > ??> @ 0x14777e0
// > ??> @ 0x1479890
// > ??> @ 0x1491bd0
// > ??> @ 0x14c1e90
// > ??> @ 0x150ccb0
// > ??> @ 0x1517b70
// > ??> @ 0x1518110
// > ??> @ 0x1518c90
// > ??> @ 0x152e6f0
// > ??> @ 0x152fef0
//
// 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 13:08:14 +0000
//
unsigned __int8 *__fastcall cocos2d::CCSprite::setOpacity(unsigned __int8 *this, unsigned __int8 a2)
{
int v2; // w20
unsigned int v3; // w3
float v4; // s8
cocos2d::CCSprite *v5; // x19
v2 = a2;
v3 = *(this + 329);
if ( v3 != a2 )
{
v4 = (float)v3;
v5 = (cocos2d::CCSprite *)this;
cocos2d::CCNodeRGBA::setOpacity((__int64)this, a2);
if ( *((_QWORD *)v5 + 46) && (v2 && v4 == 0.0 || !v2 && v4 > 0.0) )
(*(void (__fastcall **)(cocos2d::CCSprite *, __int64))(*(_QWORD *)v5 + 1200LL))(v5, 1);
return (unsigned __int8 *)cocos2d::CCSprite::updateColor(v5);
}
return this;
}