//
// tinyxml2::XMLAttribute::SetAttribute from 0x1800a02b0 to 0x1800a0371 (193 bytes)
//
// 3 xrefs:
// > tinyxml2::XMLElement::SetAttribute @ 0x1800d56e0
// > ??> @ 0x18014cf68
// > ??> @ 0x1801c14e8
//
// 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, double a2)
{
size_t v3; // rdi
void *v4; // rax
char *v5; // rax
char Str[208]; // [rsp+20h] [rbp-F8h] BYREF
sub_1800A0C60(Str, 0xC8u, "%g");
if ( (*(_DWORD *)(this + 4) & 0x200) != 0 )
j_j_free_0(*(this + 5));
*((_DWORD *)this + 8) = 0;
*(this + 5) = nullptr;
*(this + 6) = nullptr;
v3 = strlen(Str);
v4 = (void *)sub_1800E4C6C(v3 + 1);
*(this + 5) = v4;
memcpy(v4, Str, v3 + 1);
v5 = (char *)*(this + 5) + v3;
*((_DWORD *)this + 8) = 512;
*(this + 6) = v5;
}