//
// tinyxml2::XMLNode::Unlink from 0xb244b8 to 0xb24514 (92 bytes)
//
// 3 xrefs:
// > tinyxml2::XMLNode::DeleteChildren @ 0xb24538
// > tinyxml2::XMLNode::~XMLNode @ 0xb245b4
// > ??> @ 0x8c280
//
// 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
//
__int64 __fastcall tinyxml2::XMLNode::Unlink(tinyxml2::XMLNode *this, tinyxml2::XMLNode *a2)
{
__int64 result; // x0
__int64 v3; // x2
if ( *((tinyxml2::XMLNode **)this + 6) == a2 )
{
*((_QWORD *)this + 6) = *((_QWORD *)a2 + 9);
if ( *((tinyxml2::XMLNode **)this + 7) != a2 )
goto LABEL_3;
}
else if ( *((tinyxml2::XMLNode **)this + 7) != a2 )
{
goto LABEL_3;
}
*((_QWORD *)this + 7) = *((_QWORD *)a2 + 8);
LABEL_3:
result = *((_QWORD *)a2 + 8);
if ( result )
*(_QWORD *)(result + 72) = *((_QWORD *)a2 + 9);
v3 = *((_QWORD *)a2 + 9);
if ( v3 )
*(_QWORD *)(v3 + 64) = result;
*((_QWORD *)a2 + 2) = 0;
return result;
}