//
// cocos2d::CCScheduler::unscheduleUpdateForTarget from 0x1800c2a20 to 0x1800c2b57 (311 bytes)
//
// 8 xrefs:
// > cocos2d::CCNode::scheduleUpdateWithPriorityLua @ 0x1800049b1
// > cocos2d::CCNode::unscheduleUpdate @ 0x180005493
// > cocos2d::CCScheduler::unscheduleAllForTarget @ 0x1800c26cb
// > cocos2d::CCScheduler::unscheduleAllWithMinPriority @ 0x1800c2745
// > cocos2d::CCScheduler::unscheduleAllWithMinPriority @ 0x1800c276b
// > cocos2d::CCScheduler::unscheduleAllWithMinPriority @ 0x1800c2791
// > ??> @ 0x1801438a8
// > ??> @ 0x1801b9624
//
// 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
//
void __fastcall cocos2d::CCScheduler::unscheduleUpdateForTarget(
cocos2d::CCScheduler *this,
const struct cocos2d::CCObject *a2)
{
cocos2d::_hashUpdateEntry *m_pHashForUpdates; // r11
int v3; // r9d
__int64 v5; // r11
int v6; // edx
unsigned int v7; // r8d
unsigned int v8; // ecx
int v9; // edx
unsigned int v10; // r8d
unsigned int v11; // ecx
int v12; // edx
__int64 v13; // rax
__int64 v14; // rdx
__int64 v15; // rax
__int64 v16; // rax
struct cocos2d::_listEntry *v17; // rdx
int v18; // [rsp+38h] [rbp+10h]
if ( a2 )
{
v18 = (int)a2;
m_pHashForUpdates = this->m_pHashForUpdates;
v3 = (int)a2;
if ( m_pHashForUpdates )
{
v5 = *((_QWORD *)m_pHashForUpdates + 3);
v6 = (((BYTE1(a2) + ((BYTE2(a2) + (BYTE3(a2) << 8)) << 8)) << 8) + (unsigned __int8)a2 + 17973517) ^ 0x7F76D;
v7 = (((((BYTE1(v18) + ((BYTE2(v18) + (HIBYTE(v18) << 8)) << 8)) << 8) + (unsigned __int8)v3 + 17973517) ^ 0x7F76D) << 8)
^ (-1622558010 - v6);
v8 = (v7 >> 13) ^ (-17973517 - v7 - v6);
v9 = (v8 >> 12) ^ (v6 - v7 - v8);
v10 = (v9 << 16) ^ (v7 - v9 - v8);
v11 = (v10 >> 5) ^ (v8 - v10 - v9);
v12 = (v11 >> 3) ^ (v9 - v10 - v11);
v13 = *(_QWORD *)(*(_QWORD *)v5
+ 16
* ((unsigned int)(*(_DWORD *)(v5 + 8) - 1)
& (((unsigned __int64)((v12 << 10) ^ (v10 - v12 - v11)) >> 15)
^ (v11 - ((v12 << 10) ^ (v10 - v12 - v11)) - v12))));
if ( v13 )
{
v14 = *(_QWORD *)(v5 + 32);
v15 = v13 - v14;
if ( v15 )
{
while ( *(_DWORD *)(v15 + 72) != 4 || **(_DWORD **)(v15 + 64) != v3 )
{
v16 = *(_QWORD *)(v15 + 56);
if ( v16 )
{
v15 = v16 - v14;
if ( v15 )
continue;
}
return;
}
v17 = *(struct cocos2d::_listEntry **)(v15 + 8);
if ( this->m_bUpdateHashLocked )
*((_BYTE *)v17 + 29) = 1;
else
cocos2d::CCScheduler::removeUpdateFromHash(this, v17);
}
}
}
}
}