//
// ScrollingLayer::ccTouchBegan from 0x140071020 to 0x140071107 (231 bytes)
//
// 2 xrefs:
// > ??> @ 0x140535df8
// > ??> @ 0x1406c61a4
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
bool ScrollingLayer::ccTouchBegan(ScrollingLayer *a1, cocos2d::CCTouch *a2, cocos2d::CCEvent *a3)
{
__int64 v5; // rcx
cocos2d::CCDirector *v6; // rax
struct cocos2d::CCPoint v7; // rax
cocos2d::CCRect v9; // [rsp+20h] [rbp-18h] BYREF
struct cocos2d::CCPoint v10; // [rsp+40h] [rbp+8h] BYREF
struct cocos2d::CCPoint v11; // [rsp+58h] [rbp+20h] BYREF
if ( !(*(unsigned __int8 (__fastcall **)(bool *, cocos2d::CCTouch *, cocos2d::CCEvent *))(*(_QWORD *)&a1[-1].m_bReorderChildDirty
+ 328LL))(
&a1[-1].m_bReorderChildDirty,
a2,
a3) )
return 0;
ScrollingLayer::getViewRect((cocos2d::CCRect *)&a1[-1].m_bReorderChildDirty, (ScrollingLayer *)&v9);
cocos2d::CCTouch::getLocationInView(a2);
v6 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v5);
v7 = cocos2d::CCDirector::convertToGL(v6, &v11);
((void (__fastcall *)(_QWORD, _QWORD))cocos2d::CCPoint::operator=)(&v10, v7);
if ( HIDWORD(a1->m_pActionManager) != -1 || !cocos2d::CCRect::containsPoint(&v9, &v10) )
return 0;
HIDWORD(a1->m_pActionManager) = a2->m_nId;
cocos2d::CCPoint::operator=(&a1->m_pShaderProgram, &v10);
cocos2d::CCPoint::operator=(&a1->m_eGLServerState, &a1->m_pShaderProgram);
return 1;
}