//
// cocos2d::CCTouchDispatcher::touchesBegan from 0xdb226c to 0xdb236c (256 bytes)
//
// 3 xrefs:
// > `non-virtual thunk to'cocos2d::CCTouchDispatcher::touchesBegan @ 0xdb2370
// > ??> @ 0xc2158
// > ??> @ 0x15319f0
//
// 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:08:39 +0000
//
__int64 __fastcall cocos2d::CCTouchDispatcher::touchesBegan(__int64 a1, cocos2d::CCSet *this, __int64 a3)
{
cocos2d::CCTouch *v5; // x23
unsigned __int8 v6; // w0
int v8; // w0
__int64 v9; // [xsp+40h] [xbp+40h]
__int64 v10; // [xsp+48h] [xbp+48h]
__int64 v11; // [xsp+50h] [xbp+50h] BYREF
++*(_DWORD *)(a1 + 124);
if ( this )
{
v10 = a3;
v5 = (cocos2d::CCTouch *)cocos2d::CCSet::anyObject(this);
a3 = v10;
if ( v5 )
{
v6 = atomic_load((unsigned __int8 *)byte_15624E8);
if ( (v6 & 1) == 0 )
{
v8 = _cxa_guard_acquire(byte_15624E8);
a3 = v10;
if ( v8 )
{
cocos2d::CCPoint::CCPoint(flt_15624F0, (const cocos2d::CCPoint *)&unk_15624F8);
_cxa_guard_release(byte_15624E8);
a3 = v10;
}
}
v9 = a3;
cocos2d::CCTouch::getLocation(&v11, v5);
cocos2d::CCPoint::operator=(flt_15624F0, (float *)&v11);
a3 = v9;
}
}
if ( *(_BYTE *)(a1 + 105) )
cocos2d::CCTouchDispatcher::touches(a1, this, a3, 0);
return _stack_chk_guard;
}