//
// cocos2d::CCScheduler::unscheduleAllForTarget from 0x7b5a5c to 0x7b5b52 (246 bytes)
//
// 5 xrefs:
// > cocos2d::extension::AssetsManager::Helper::~Helper @ 0x7a567e
// > cocos2d::extension::WsThreadHelper::~WsThreadHelper @ 0x7b2cd6
// > cocos2d::extension::WebSocket::close @ 0x7b2e9c
// > cocos2d::CCScheduler::unscheduleAllWithMinPriority @ 0x7b5b74
// > cocos2d::CCNode::unscheduleAllSelectors @ 0x7c4da4
//
// 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:11 +0000
//
int __fastcall cocos2d::CCScheduler::unscheduleAllForTarget(int this, cocos2d::CCObject *a2, int a3)
{
int v3; // r4
int v5; // r1
_DWORD *v6; // r7
int v7; // r0
unsigned int v8; // r2
unsigned int v9; // r3
int v10; // r0
unsigned int v11; // r2
unsigned int v12; // r3
int v13; // r0
_DWORD *v14; // r6
int v15; // r3
cocos2d::CCObject *v16; // [sp+4h] [bp-4h] BYREF
v3 = this;
v16 = a2;
if ( a2 )
{
v5 = *(_DWORD *)(this + 72);
if ( v5 )
{
v6 = *(_DWORD **)(v5 + 20);
v7 = ((unsigned __int8)v16 + 17973517 + (HIBYTE(v16) << 24) + (BYTE2(v16) << 16) + (BYTE1(v16) << 8)) ^ 0x7F76D;
v8 = (-1622558010 - v7) ^ (v7 << 8);
v9 = (-17973517 - v7 - v8) ^ (v8 >> 13);
v10 = (v7 - v8 - v9) ^ (v9 >> 12);
v11 = (v8 - v9 - v10) ^ (v10 << 16);
v12 = (v9 - v10 - v11) ^ (v11 >> 5);
v13 = (v10 - v11 - v12) ^ (v12 >> 3);
a3 = 12
* (((v12 - v13 - ((v11 - v12 - v13) ^ (v13 << 10))) ^ (((v11 - v12 - v13) ^ (v13 << 10)) >> 15)) & (v6[1] - 1));
v14 = *(_DWORD **)(*v6 + a3);
if ( v14 )
v14 = (_DWORD *)((char *)v14 - v6[5]);
while ( v14 )
{
a3 = v14[11];
if ( a3 == 4 && !memcmp((const void *)v14[10], &v16, 4u) )
{
if ( cocos2d::ccArrayContainsObject(*v14, v14[3]) && !*((_BYTE *)v14 + 16) )
{
cocos2d::CCObject::retain((cocos2d::CCObject *)v14[3]);
*((_BYTE *)v14 + 16) = 1;
}
cocos2d::ccArrayRemoveAllObjects(*v14);
if ( *(_DWORD **)(v3 + 76) == v14 )
*(_BYTE *)(v3 + 80) = 1;
else
cocos2d::CCScheduler::removeHashElement(v3, v14);
return cocos2d::CCScheduler::unscheduleUpdateForTarget(v3, a2, a3);
}
v15 = v14[9];
if ( !v15 )
return cocos2d::CCScheduler::unscheduleUpdateForTarget(v3, a2, a3);
v14 = (_DWORD *)(v15 - v6[5]);
}
}
return cocos2d::CCScheduler::unscheduleUpdateForTarget(v3, a2, a3);
}
return this;
}