//
// cocos2d::CCLayer::registerWithTouchDispatcher from 0x7d6ef8 to 0x7d6f3e (70 bytes)
//
// 1 xrefs:
// > LevelBrowserLayer::registerWithTouchDispatcher @ 0x4a9488
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:00:40 +0000
//
int __fastcall cocos2d::CCLayer::registerWithTouchDispatcher(cocos2d::CCLayer *this)
{
int v2; // r0
cocos2d::CCTouchDispatcher *v3; // r0
int v4; // r3
cocos2d::CCTouchDelegate *v5; // r1
cocos2d::CCTouchDelegate *v6; // r2
int v7; // r2
char v8; // r3
v2 = cocos2d::CCDirector::sharedDirector(this);
v3 = (cocos2d::CCTouchDispatcher *)(*(int (__fastcall **)(int))(*(_DWORD *)v2 + 80))(v2);
v4 = *((_DWORD *)this + 73);
v5 = (cocos2d::CCLayer *)((char *)this + 264);
if ( v4 )
{
if ( *(_BYTE *)(v4 + 60) )
{
v6 = nullptr;
return cocos2d::CCTouchDispatcher::addStandardDelegate(v3, v5, v6);
}
v7 = *(_DWORD *)(v4 + 64);
v8 = *(_BYTE *)(v4 + 68);
}
else
{
v6 = *((cocos2d::CCTouchDelegate **)this + 77);
if ( !v6 )
return cocos2d::CCTouchDispatcher::addStandardDelegate(v3, v5, v6);
v7 = *((_DWORD *)this + 76);
v8 = 1;
}
return cocos2d::CCTouchDispatcher::addTargetedDelegate(v3, v5, v7, v8);
}