//
// GJUINode::touchEnded from 0x1004c5be0 to 0x1004c5c70 (144 bytes)
//
// 2 xrefs:
// > UILayer::processUINodeTouch @ 0x1004c56c5
// > UILayer::processUINodeTouch @ 0x1004c589c
//
// 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 12:31:07 +0000
//
__int64 __fastcall GJUINode::touchEnded(__int64 a1)
{
__int64 result; // rax
__int64 v3; // rdi
__int64 v4; // rdi
_QWORD v5[2]; // [rsp+0h] [rbp-10h] BYREF
v5[0] = result;
*(_DWORD *)(a1 + 352) = -1;
v3 = *(_QWORD *)(a1 + 320);
if ( v3 )
{
BYTE6(v5[0]) = -1;
WORD2(v5[0]) = -1;
result = (*(__int64 (__fastcall **)(__int64, char *))(*(_QWORD *)v3 + 960LL))(v3, (char *)v5 + 4);
}
if ( *(_BYTE *)(a1 + 381) == 1 )
{
if ( *(_BYTE *)(a1 + 382) == 1 )
result = (*(__int64 (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 320) + 344LL))(*(_QWORD *)(a1 + 320), 0);
}
else
{
v4 = *(_QWORD *)(a1 + 328);
if ( v4 )
{
BYTE2(v5[0]) = -1;
LOWORD(v5[0]) = -1;
result = (*(__int64 (__fastcall **)(__int64, _QWORD *))(*(_QWORD *)v4 + 960LL))(v4, v5);
}
}
*(_DWORD *)(a1 + 388) = 0;
return result;
}