//
// cocos2d::CCDictionary::removeObjectsForKeys from 0x1002fa540 to 0x1002fa663 (291 bytes)
//
// 3 xrefs:
// > cocos2d::CCSpriteFrameCache::removeSpriteFramesFromDictionary @ 0x100308dd1
// > cocos2d::CCSpriteFrameCache::removeSpriteFramesFromTexture @ 0x1003090a1
// > cocos2d::CCTextureCache::removeTexture @ 0x1006c1ee7
//
// 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 12:28:30 +0000
//
void __fastcall cocos2d::CCDictionary::removeObjectsForKeys(__int64 a1, __int64 a2)
{
unsigned int *v2; // rax
__int64 v3; // r14
_QWORD *v4; // rbx
const char *CString; // r12
size_t v6; // rax
size_t v7; // r15
char *v8; // r13
__int64 v9; // rax
size_t v10; // r14
unsigned __int64 v11; // [rsp+0h] [rbp-50h]
_QWORD __dst[2]; // [rsp+10h] [rbp-40h] BYREF
void *__p; // [rsp+20h] [rbp-30h]
if ( a2 )
{
v2 = *(unsigned int **)(a2 + 56);
if ( *v2 )
{
v3 = a1;
v4 = *((_QWORD **)v2 + 2);
v11 = (unsigned __int64)&v4[*v2 - 1];
do
{
if ( !*v4 )
return;
CString = (const char *)cocos2d::CCString::getCString(*v4);
v6 = strlen(CString);
if ( v6 >= 0xFFFFFFFFFFFFFFF8LL )
sub_100003630();
v7 = v6;
if ( v6 >= 0x17 )
{
v9 = v6 | 7;
v10 = 26;
if ( (v7 | 7) != 0x17 )
v10 = v9 + 1;
v8 = (char *)operator new(v10);
__p = v8;
__dst[0] = v10 + 1;
__dst[1] = v7;
v3 = a1;
}
else
{
LOBYTE(__dst[0]) = 2 * v6;
v8 = (char *)__dst + 1;
if ( !v6 )
goto LABEL_14;
}
memmove(v8, CString, v7);
LABEL_14:
v8[v7] = 0;
cocos2d::CCDictionary::removeObjectForKey(v3, (char *)__dst);
if ( (__dst[0] & 1) != 0 )
operator delete(__p);
++v4;
}
while ( (unsigned __int64)v4 <= v11 );
}
}
}