//
// DS_Dictionary::setArrayForKey from 0x18001e710 to 0x18001e850 (320 bytes)
//
// 5 xrefs:
// > DS_Dictionary::setObjectForKey @ 0x18001f47f
// > ??> @ 0x180133520
// > ??> @ 0x180133554
// > ??> @ 0x1801438a8
// > ??> @ 0x1801aec50
//
// 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 DS_Dictionary::setArrayForKey(DS_Dictionary *this, const char *a2, struct cocos2d::CCArray *a3)
{
const char *v5; // r8
__int64 v6; // rax
const char *v7; // r8
unsigned int i; // ebx
struct cocos2d::CCString *v9; // rdi
cocos2d::CCString *v10; // rax
std::string *CString; // rax
__int64 v12; // [rsp+50h] [rbp+18h] BYREF
char v13; // [rsp+58h] [rbp+20h] BYREF
if ( a3 )
{
DS_Dictionary::setSubDictForKey(this, a2, 0, 1);
pugi::xml_node::xml_node((cocos2d::CCThread *)&v12);
v5 = "k";
if ( this->compatible )
v5 = "key";
v12 = *(_QWORD *)sub_18007F870(&this->dictTree._Mypair._Myval2._Mylast[-1], &v13, v5);
v6 = sub_18007F910(&v12, &v13, 3);
sub_180085410(v6, "_isArr");
v7 = "t";
if ( this->compatible )
v7 = "true";
sub_180080EE0(&this->dictTree._Mypair._Myval2._Mylast[-1], &v13, v7, &v12);
for ( i = 0; i < (unsigned int)cocos2d::CCArray::count(a3); ++i )
{
v9 = cocos2d::CCArray::stringAtIndex(a3, i);
v10 = cocos2d::CCString::createWithFormat("k_%i", i);
CString = cocos2d::CCString::getCString(v10);
DS_Dictionary::setObjectForKey(this, CString->m_data.m_smallStorage._Elems, v9);
}
if ( (unsigned __int64)(this->dictTree._Mypair._Myval2._Mylast - this->dictTree._Mypair._Myval2._Myfirst) > 1 )
--this->dictTree._Mypair._Myval2._Mylast;
}
}