//
// tinyxml2::XMLAttribute::SetAttribute from 0x1800a0060 to 0x1800a011c (188 bytes)
//
// 3 xrefs:
// > tinyxml2::XMLElement::SetAttribute @ 0x1800d5698
// > ??> @ 0x18014cf68
// > ??> @ 0x1801c14c4
//
// 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:13 +0000
//
void __fastcall tinyxml2::XMLAttribute::SetAttribute(void **this)
{
size_t v2; // rdi
void *v3; // rax
char *v4; // rax
char Str[208]; // [rsp+20h] [rbp-F8h] BYREF
sub_1800A0C60(Str, 0xC8u, "%d");
if ( (*(_DWORD *)(this + 4) & 0x200) != 0 )
j_j_free_0(*(this + 5));
*((_DWORD *)this + 8) = 0;
*(this + 5) = nullptr;
*(this + 6) = nullptr;
v2 = strlen(Str);
v3 = (void *)sub_1800E4C6C(v2 + 1);
*(this + 5) = v3;
memcpy(v3, Str, v2 + 1);
v4 = (char *)*(this + 5) + v2;
*((_DWORD *)this + 8) = 512;
*(this + 6) = v4;
}