//
// tinyxml2::XMLPrinter::CloseElement from 0x18009c740 to 0x18009c7eb (171 bytes)
//
// 3 xrefs:
// > tinyxml2::XMLPrinter::VisitExit @ 0x1800a1104
// > ??> @ 0x18014cf68
// > ??> @ 0x1801c0f3c
//
// 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:12 +0000
//
void __fastcall tinyxml2::XMLPrinter::CloseElement(tinyxml2::XMLPrinter *this)
{
__int64 v2; // rdx
const char *v3; // rdi
int v4; // eax
--*((_DWORD *)this + 6);
v2 = *((int *)this + 65);
*((_DWORD *)this + 65) = v2 - 1;
v3 = *(const char **)(*((_QWORD *)this + 21) + 8 * v2 - 8);
if ( *((_BYTE *)this + 8) )
{
tinyxml2::XMLPrinter::Print(this, "/>");
}
else
{
if ( *((int *)this + 7) < 0 && !*((_BYTE *)this + 33) )
{
tinyxml2::XMLPrinter::Print(this, "\n");
tinyxml2::XMLPrinter::PrintSpace(this, *((_DWORD *)this + 6));
}
tinyxml2::XMLPrinter::Print(this, "%s>", v3);
}
v4 = *((_DWORD *)this + 6);
if ( *((_DWORD *)this + 7) == v4 )
*((_DWORD *)this + 7) = -1;
if ( !v4 && !*((_BYTE *)this + 33) )
tinyxml2::XMLPrinter::Print(this, "\n");
*((_BYTE *)this + 8) = 0;
}