//
// EmotePickerPopup::refreshEnabled from 0x140124640 to 0x14012477e (318 bytes)
//
// 6 xrefs:
// > EmotePickerPopup::init @ 0x140123c11
// > EmotePickerPopup::textChanged @ 0x140123c67
// > EmotePickerPopup::onPickEmote @ 0x1401249a3
// > ??> @ 0x1408980b8
// > ??> @ 0x140898114
// > ??> @ 0x1409168c8
//
// This function is hookable on this platform (idp: pc, 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 11:26:57 +0000
//
void __fastcall EmotePickerPopup::refreshEnabled(__int64 a1, __int64 a2, __int64 a3, double a4)
{
unsigned __int8 canAddEmote; // al
unsigned __int8 v6; // bp
__int64 v7; // rcx
_QWORD *v8; // rsi
__int64 v9; // rbx
unsigned __int64 i; // rdi
__int64 v11; // rbx
cocos2d::CCArray *v12; // rax
struct cocos2d::CCObject *v13; // rax
__int64 v14; // rdx
if ( *(_QWORD *)(a1 + 1032) )
{
canAddEmote = EmotePickerPopup::canAddEmote(a1, a2, a3, a4);
v6 = canAddEmote;
if ( canAddEmote != *(_DWORD *)(a1 + 1192) )
{
v7 = *(_QWORD *)(a1 + 1032);
*(_DWORD *)(a1 + 1192) = canAddEmote;
if ( (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v7 + 480LL))(v7) )
{
if ( **(_DWORD **)((*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1032) + 480LL))(*(_QWORD *)(a1 + 1032))
+ 56) )
{
v8 = *(_QWORD **)(*(_QWORD *)((*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1032) + 480LL))(*(_QWORD *)(a1 + 1032))
+ 56)
+ 16LL);
v9 = *(_QWORD *)(*(_QWORD *)((*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1032) + 480LL))(*(_QWORD *)(a1 + 1032))
+ 56)
+ 16LL);
for ( i = v9
+ 8
* (**(unsigned int **)((*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1032) + 480LL))(*(_QWORD *)(a1 + 1032))
+ 56)
- 1LL); (unsigned __int64)v8 <= i; ++v8 )
{
v11 = *v8;
if ( !*v8 )
break;
(*(void (__fastcall **)(_QWORD, _QWORD))(*(_QWORD *)v11 + 936LL))(*v8, v6);
v12 = (cocos2d::CCArray *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v11 + 480LL))(v11);
v13 = cocos2d::CCArray::objectAtIndex(v12, 0);
v14 = 90;
if ( v6 )
v14 = 255;
(*(void (__fastcall **)(__int64, __int64))(*((_QWORD *)v13 + 40) + 40LL))((__int64)v13 + 320, v14);
}
}
}
}
}
}