//
// GameManager::dpadConfigToString from 0x140186490 to 0x14018677b (747 bytes)
//
// 11 xrefs:
// > GameManager::saveDPadLayout @ 0x140185e79
// > GameManager::saveDPadLayout @ 0x140185f9d
// > GameManager::saveDPadLayout @ 0x140186010
// > GameManager::saveDPadLayout @ 0x14018607c
// > GameManager::saveDPadLayout @ 0x1401860e8
// > GameManager::encodeDataTo @ 0x140189715
// > GameManager::encodeDataTo @ 0x140189743
// > GameManager::encodeDataTo @ 0x140189771
// > GameManager::encodeDataTo @ 0x14018979f
// > GameManager::encodeDataTo @ 0x1401897cd
// > ??> @ 0x1406cb64c
//
// 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
//
// Hidden C++ exception states: #wind=1
char *__fastcall GameManager::dpadConfigToString(__int64 a1, char *a2, unsigned int *a3)
{
_BYTE *v5; // rax
size_t v6; // r8
const char *v8; // [rsp+20h] [rbp-E0h] BYREF
__int64 v9; // [rsp+28h] [rbp-D8h]
_BYTE v10[528]; // [rsp+40h] [rbp-C0h] BYREF
v8 = a2;
fmt::BasicWriter::BasicWriter(v10);
fmt::BasicWriter::operator<<(v10, *a3);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10, a3[1]);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10, a3[4]);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10);
if ( !*((_BYTE *)a3 + 36) )
{
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10, *((unsigned __int8 *)a3 + 24));
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10);
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10, *((unsigned __int8 *)a3 + 25));
v8 = ",";
v9 = 0;
fmt::BasicWriter::operator<<(v10, &v8);
fmt::BasicWriter::operator<<(v10, *((unsigned __int8 *)a3 + 38));
}
v5 = (_BYTE *)fmt::BasicWriter::c_str(v10);
*(_OWORD *)a2 = 0;
*((_QWORD *)a2 + 2) = 0;
*((_QWORD *)a2 + 3) = 0;
v6 = -1;
do
++v6;
while ( v5[v6] );
sub_14003A930(a2, v5, v6);
fmt::BasicWriter::~BasicWriter(v10);
return a2;
}