//
// DS_Dictionary::setVec2ArrayForKey from 0x10017fed0 to 0x100180273 (931 bytes)
//
// 1 xrefs:
// > DS_Dictionary::setVec2ArrayForKey_1 @ 0x10017fec7
//
// 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::setVec2ArrayForKey(
DS_Dictionary *a1,
const char *a2,
std::vector *const a3,
bool a4)
{
DS_Dictionary *v6; // r14
const char *v7; // r12
bool v8; // zf
const char *v9; // rsi
char *v10; // rax
const char *v11; // rsi
__int64 v12; // rax
const char *v13; // rsi
unsigned __int64 v14; // r14
const char *v15; // rsi
char *v16; // rsi
const char *v17; // rsi
_QWORD v18[2]; // [rsp+8h] [rbp-1A8h] BYREF
__int64 (__fastcall **v19)(); // [rsp+18h] [rbp-198h] BYREF
void *v20; // [rsp+20h] [rbp-190h] BYREF
std::locale v21; // [rsp+28h] [rbp-188h] BYREF
char v22; // [rsp+60h] [rbp-150h]
void *v23; // [rsp+70h] [rbp-140h]
__int64 (__fastcall **v24)(); // [rsp+88h] [rbp-128h] BYREF
__int64 v25; // [rsp+120h] [rbp-90h] BYREF
__int64 v26; // [rsp+128h] [rbp-88h] BYREF
__int64 (__fastcall **v27)(); // [rsp+130h] [rbp-80h]
__int64 (__fastcall **v28)(); // [rsp+138h] [rbp-78h]
__int64 (__fastcall **v29)(); // [rsp+140h] [rbp-70h]
__int64 (__fastcall **v30)(); // [rsp+148h] [rbp-68h]
void (__cdecl **v31)(std::streambuf *__hidden); // [rsp+150h] [rbp-60h]
char v32; // [rsp+158h] [rbp-58h] BYREF
char v33; // [rsp+159h] [rbp-57h] BYREF
void *__p; // [rsp+168h] [rbp-48h]
__int64 v35; // [rsp+170h] [rbp-40h] BYREF
__int64 v36; // [rsp+178h] [rbp-38h] BYREF
DS_Dictionary *v37; // [rsp+180h] [rbp-30h]
LODWORD(v37) = a4;
v6 = a1;
DS_Dictionary::removeKey_1(a1, a2);
pugi::xml_node::xml_node(&v36);
pugi::xml_node::xml_node(&v35);
v7 = "k";
v8 = (_DWORD)v37 == 0;
v37 = a1;
if ( v8 )
goto LABEL_11;
v9 = "k";
if ( a1->compatible )
v9 = "key";
v18[0] = sub_10063B550(&a1->dictTree.__end_[-1], v9);
if ( !sub_10063B3F0(v18) )
{
LABEL_10:
v6 = v37;
LABEL_11:
if ( v6->compatible )
v7 = "key";
v12 = sub_10063C660(&v6->dictTree.__end_[-1], v7);
goto LABEL_14;
}
while ( 1 )
{
v10 = (char *)sub_10063B880(v18);
if ( !sub_1001796D0(v10, (char *)a2) )
break;
v11 = "key";
if ( !v37->compatible )
v11 = "k";
v18[0] = sub_10063B730(v18, v11);
if ( !sub_10063B3F0(v18) )
goto LABEL_10;
}
v6 = v37;
v17 = "k";
if ( v37->compatible )
v17 = "key";
v12 = sub_10063C8D0(&v37->dictTree.__end_[-1], v17, v18);
LABEL_14:
v36 = v12;
v18[0] = sub_10063C150(&v36, 3);
sub_10063BA40(v18, a2);
v13 = "a";
if ( v6->compatible )
v13 = "array";
v35 = sub_10063C7D0(&v6->dictTree.__end_[-1], v13, &v36);
if ( a3->__end_ != a3->__begin_ )
{
v14 = 0;
v28 = &off_1008C3D68;
v29 = off_1008C3DB8;
v27 = off_1008C3D90;
v30 = &off_1008C3F58;
v31 = &`vtable for'std::streambuf.~basic_streambuf;
do
{
sub_10017F730((__int64)v18);
sub_100183CF0(&v19, "{", 1);
std::ostream::operator<<(&v19, a3->__begin_[v14].x);
sub_100183CF0(&v19, ",", 1);
std::ostream::operator<<(&v19, a3->__begin_[v14].y);
sub_100183CF0(&v19, "}", 1);
v15 = "s";
if ( v37->compatible )
v15 = "string";
v26 = sub_10063C660(&v35, v15);
v25 = sub_10063C150(&v26, 3);
sub_1001837B0(&v32, &v20);
v16 = &v33;
if ( (v32 & 1) != 0 )
v16 = (char *)__p;
sub_10063BA40(&v25, v16);
if ( (v32 & 1) != 0 )
operator delete(__p);
v18[0] = v28;
v24 = v29;
v19 = v27;
v20 = v30;
if ( (v22 & 1) != 0 )
operator delete(v23);
v20 = v31;
std::locale::~locale(&v21);
std::iostream::~iostream(v18, off_1008C3DD0);
std::ios::~ios(&v24);
++v14;
}
while ( a3->__end_ - a3->__begin_ > v14 );
}
}