//
// cocos2d::CCDictionary::allKeysForObject from 0x180009a60 to 0x180009bc1 (353 bytes)
//
// 3 xrefs:
// > cocos2d::CCTextureCache::removeTexture @ 0x1800ad041
// > ??> @ 0x18014cf68
// > ??> @ 0x1801b7c90
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// 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 11:21:19 +0000
//
// Hidden C++ exception states: #wind=2
struct cocos2d::CCArray *__fastcall cocos2d::CCDictionary::allKeysForObject(
cocos2d::CCDictionary *this,
struct cocos2d::CCObject *a2)
{
__int64 v4; // rax
cocos2d::CCArray *v5; // rbp
int v6; // ecx
__int64 v7; // rbx
__int64 i; // rdi
cocos2d::CCString *v9; // rax
struct cocos2d::CCObject *v10; // rbx
__int64 v11; // rbx
__int64 j; // rsi
cocos2d::CCObject *v13; // rax
struct cocos2d::CCObject *v14; // rdi
int v15; // ebx
v4 = *((_QWORD *)this + 7);
if ( !v4 || *(int *)(*(_QWORD *)(v4 + 272) + 16LL) <= 0 )
return nullptr;
v5 = cocos2d::CCArray::create();
v6 = *((_DWORD *)this + 16);
if ( v6 == 1 )
{
v7 = *((_QWORD *)this + 7);
if ( v7 )
{
for ( i = *(_QWORD *)(v7 + 288); ; i = *(_QWORD *)(i + 288) )
{
if ( a2 == *(struct cocos2d::CCObject **)(v7 + 264) )
{
v9 = (cocos2d::CCString *)sub_1800E4AC0(0x58u);
if ( v9 )
v10 = (struct cocos2d::CCObject *)cocos2d::CCString::CCString(v9, (const char *)v7);
else
v10 = nullptr;
cocos2d::CCArray::addObject(v5, v10);
if ( v10 )
cocos2d::CCObject::release(v10);
}
v7 = i;
if ( !i )
break;
}
}
}
else if ( v6 == 2 )
{
v11 = *((_QWORD *)this + 7);
if ( v11 )
{
for ( j = *(_QWORD *)(v11 + 288); ; j = *(_QWORD *)(j + 288) )
{
if ( a2 == *(struct cocos2d::CCObject **)(v11 + 264) )
{
v13 = (cocos2d::CCObject *)sub_1800E4AC0(0x40u);
v14 = v13;
if ( v13 )
{
v15 = *(_DWORD *)(v11 + 256);
cocos2d::CCObject::CCObject(v13);
*(_QWORD *)v14 = &cocos2d::CCInteger::`vftable';
*((_DWORD *)v14 + 14) = v15;
}
else
{
v14 = nullptr;
}
cocos2d::CCArray::addObject(v5, v14);
if ( v14 )
cocos2d::CCObject::release(v14);
}
v11 = j;
if ( !j )
break;
}
}
}
return v5;
}