//
// MenuLayer::updateNewsBadge from 0x6ea8e0 to 0x6eaa00 (288 bytes)
//
// 4 xrefs:
// > MenuLayer::onNews @ 0x6eaa48
// > MenuLayer::musicActionFinished @ 0x6eaa58
// > MenuLayer::init @ 0x6ec084
// > ??> @ 0x4c288
//
// 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:51:45 +0000
//
__int64 __fastcall MenuLayer::updateNewsBadge(MenuLayer *this)
{
__int64 v2; // x0
MusicDownloadManager *v3; // x0
MusicDownloadManager *v4; // x0
const char *v5; // x1
__int64 v7; // x21
const cocos2d::CCSize *v8; // x0
void (__fastcall *v9)(__int64, _BYTE *); // x22
float v10[2]; // [xsp+58h] [xbp+58h] BYREF
_BYTE v11[8]; // [xsp+60h] [xbp+60h] BYREF
v2 = *((_QWORD *)this + 61);
if ( v2 )
{
v3 = (MusicDownloadManager *)(*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v2 + 584LL))(v2, 1);
v4 = (MusicDownloadManager *)MusicDownloadManager::sharedState(v3);
if ( (unsigned __int8)MusicDownloadManager::hasUnreadNews(v4) )
{
v7 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"exMark_001.png", v5);
(*(void (__fastcall **)(__int64, float))(*(_QWORD *)v7 + 160LL))(v7, 0.8);
v8 = (const cocos2d::CCSize *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 61) + 328LL))(*((_QWORD *)this + 61));
cocos2d::CCSize::CCSize((cocos2d::CCSize *)v10, v8);
v9 = *(void (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)v7 + 184LL);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v11, (float)(v10[0] - 8.0) * 0.8, v10[1] - 7.0);
v9(v7, v11);
(*(void (__fastcall **)(_QWORD, __int64, __int64))(**((_QWORD **)this + 61) + 464LL))(
*((_QWORD *)this + 61),
v7,
10);
}
}
return _stack_chk_guard;
}