//
// ColorChannelSprite::updateOpacity from 0x9f888c to 0x9f8a10 (388 bytes)
//
// 3 xrefs:
// > ColorChannelSprite::updateValues @ 0x9f8b8c
// > ColorChannelSprite::updateValues @ 0x9f8c40
// > ??> @ 0xb9188
//
// 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:15 +0000
//
__int64 __fastcall ColorChannelSprite::updateOpacity(ColorChannelSprite *this, float a2, __int64 a3, const char *a4)
{
__int64 v6; // x0
const char **v8; // x21
void (__fastcall *v9)(const char **, __int64); // x22
cocos2d::CCString *v10; // x0
__int64 CString; // x0
__int64 v12; // x0
__int64 v13; // x22
void (__fastcall *v14)(__int64, _BYTE *); // x23
__int64 v15; // x0
float v16; // [xsp+50h] [xbp+50h]
_BYTE v17[8]; // [xsp+70h] [xbp+70h] BYREF
if ( a2 == 1.0 )
{
v6 = *((_QWORD *)this + 76);
if ( v6 )
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v6 + 344LL))(v6, 0);
}
else
{
v8 = *((const char ***)this + 76);
if ( !v8 )
{
v12 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)&byte_11E1A70, "bigFont.fnt", a4);
*((_QWORD *)this + 76) = v12;
(*(void (__fastcall **)(ColorChannelSprite *, __int64))(*(_QWORD *)this + 456LL))(this, v12);
v13 = *((_QWORD *)this + 76);
v14 = *(void (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)v13 + 184LL);
v16 = *(float *)(*(__int64 (__fastcall **)(ColorChannelSprite *))(*(_QWORD *)this + 328LL))(this) * 0.5;
v15 = (*(__int64 (__fastcall **)(ColorChannelSprite *))(*(_QWORD *)this + 328LL))(this);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v17, v16, (float)(*(float *)(v15 + 4) * 0.5) + -9.5);
v14(v13, v17);
(*(void (__fastcall **)(_QWORD, float))(**((_QWORD **)this + 76) + 160LL))(*((_QWORD *)this + 76), 0.3);
v8 = *((const char ***)this + 76);
}
v9 = *((void (__fastcall **)(const char **, __int64))*v8 + 116);
v10 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%0.2f", *v8, a2);
CString = cocos2d::CCString::getCString(v10);
v9(v8, CString);
(*(void (__fastcall **)(_QWORD, __int64))(**((_QWORD **)this + 76) + 344LL))(*((_QWORD *)this + 76), 1);
}
return _stack_chk_guard;
}