//
// EmotePickerPopup::ccTouchBegan from 0xcb8cc0 to 0xcb8d98 (216 bytes)
//
// 3 xrefs:
// > `non-virtual thunk to'EmotePickerPopup::ccTouchBegan @ 0xcb8d9c
// > ??> @ 0x8d5b0
// > ??> @ 0x14fa120
//
// 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:06:13 +0000
//
__int64 __fastcall EmotePickerPopup::ccTouchBegan(_QWORD *a1, cocos2d::CCTouch *a2)
{
unsigned __int8 v4; // w0
unsigned int v5; // w20
__int64 v7; // x24
__int64 v8; // [xsp+48h] [xbp+48h] BYREF
_BYTE v9[8]; // [xsp+50h] [xbp+50h] BYREF
v4 = EditorWindowPopup::ccTouchBegan();
v5 = v4;
if ( !v4 )
{
cocos2d::CCTouch::getLocation(&v8, a2);
v7 = a1[146];
if ( !v7
|| (cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v9, (const cocos2d::CCPoint *)&v8),
!(unsigned __int8)CCTextInputNode::containsTouchPoint(v7, (const cocos2d::CCPoint *)v9)) )
{
if ( !(unsigned __int8)cocos2d::CCRect::containsPoint(
(cocos2d::CCRect *)(a1 + 149),
(const cocos2d::CCPoint *)&v8) )
{
v5 = 0;
(*(void (__fastcall **)(_QWORD *, _QWORD))(*a1 + 1368LL))(a1, 0);
}
}
}
return v5;
}