//
// cocos2d::CCTouchDispatcher::setPriority from 0x808598 to 0x8085cc (52 bytes)
//
// 1 xrefs:
// > cocos2d::CCMenu::setHandlerPriority @ 0x7dbe06
//
// 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:01:27 +0000
//
int __fastcall cocos2d::CCTouchDispatcher::setPriority(cocos2d::CCArray **this, int a2, cocos2d::CCTouchDelegate *a3)
{
cocos2d::CCTouchHandler *Handler; // r6
int result; // r0
Handler = cocos2d::CCTouchDispatcher::findHandler((cocos2d::CCTouchDispatcher *)this, a3);
result = cocos2d::CCTouchHandler::getPriority(Handler);
if ( result != a2 )
{
cocos2d::CCTouchHandler::setPriority(Handler, a2);
cocos2d::CCTouchDispatcher::rearrangeHandlers((cocos2d::CCTouchDispatcher *)this, *(this + 14));
return cocos2d::CCTouchDispatcher::rearrangeHandlers((cocos2d::CCTouchDispatcher *)this, *(this + 15));
}
return result;
}