//
// sub_180082820 from 0x180082820 to 0x1800828d3 (179 bytes)
//
// 24 xrefs:
// > DS_Dictionary::setArrayForKey @ 0x18001e8ab
// > DS_Dictionary::setArrayForKey @ 0x18001e944
// > DS_Dictionary::setBoolForKey @ 0x18001eb2c
// > DS_Dictionary::setFloatForKey @ 0x18001f10c
// > DS_Dictionary::setFloatForKey @ 0x18001f1f4
// > DS_Dictionary::setIntegerForKey @ 0x18001f39e
// > DS_Dictionary::setIntegerForKey @ 0x18001f486
// > DS_Dictionary::setRectArrayForKey @ 0x18001f7ec
// > DS_Dictionary::setRectArrayForKey @ 0x18001facb
// > DS_Dictionary::setRectForKey @ 0x18001fe2c
// > DS_Dictionary::setRectForKey @ 0x18001fe9b
// > DS_Dictionary::setStringArrayForKey @ 0x1800200ac
// > DS_Dictionary::setStringArrayForKey @ 0x18002015e
// > DS_Dictionary::setStringForKey @ 0x1800202ee
// > DS_Dictionary::setStringForKey @ 0x180020353
// > DS_Dictionary::setSubDictForKey @ 0x180020400
// > DS_Dictionary::setSubDictForKey @ 0x18002055c
// > DS_Dictionary::setVec2ArrayForKey @ 0x18002074c
// > DS_Dictionary::setVec2ArrayForKey @ 0x1800209e6
// > DS_Dictionary::setVec2ForKey @ 0x180020d01
// > DS_Dictionary::setVec2ForKey @ 0x180020d70
// > ??> @ 0x1801455b0
// > ??> @ 0x1801455c0
// > ??> @ 0x1801bf2f8
//
// 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:22:03 +0000
//
_QWORD *__fastcall sub_180082820(_QWORD **a1, _QWORD *a2, __int64 a3)
{
_QWORD *v3; // rcx
int v4; // esi
unsigned int v6; // eax
_DWORD *v7; // rax
_DWORD *v8; // rbx
v3 = *a1;
v4 = a3;
if ( !v3 || (v6 = *(_DWORD *)v3 & 7, v6 > 1) || (unsigned int)a3 <= 1 || v6 && (unsigned int)(a3 - 7) <= 1 )
{
*a2 = 0;
return a2;
}
else
{
v7 = (_DWORD *)sub_1800828E0(v3, *(_QWORD *)(*v3 & 0xFFFFFFFFFFFFFFE0uLL), a3);
v8 = v7;
if ( v4 == 7 && v7 && ((*v7 & 7) == 1 || (*v7 & 7u) - 5 <= 1) )
sub_180088820(v7 + 4, v7, 16, "xml");
*a2 = v8;
return a2;
}
}