//
// sub_140063580 from 0x140063580 to 0x140063636 (182 bytes)
//
// 4 xrefs:
// > sub_14005E190 @ 0x14005e206
// > sub_140063580 @ 0x140063604
// > sub_140063580 @ 0x140063616
// > ??> @ 0x1406c5cb8
//
// 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
__int64 __fastcall sub_140063580(__int64 *a1, __int64 a2, __int64 a3)
{
__int64 v6; // r14
char *v7; // rbx
__int64 v9; // rax
__int64 v10; // rcx
v6 = *a1;
if ( !*(_BYTE *)(a2 + 25) )
{
v7 = (char *)operator new(0x40u);
*(_OWORD *)(v7 + 28) = *(_OWORD *)(a2 + 28);
*(_OWORD *)(v7 + 44) = *(_OWORD *)(a2 + 44);
*(_QWORD *)v7 = v6;
*((_QWORD *)v7 + 2) = v6;
*((_WORD *)v7 + 12) = 0;
*((_QWORD *)v7 + 1) = a3;
v7[24] = *(_BYTE *)(a2 + 24);
if ( *(_BYTE *)(v6 + 25) )
v6 = (__int64)v7;
try
{
*(_QWORD *)v7 = sub_140063580(a1, *(_QWORD *)a2, v7);
*((_QWORD *)v7 + 2) = sub_140063580(a1, *(_QWORD *)(a2 + 16), v7);
}
catch ( ... )
{
v9 = sub_14005EB70((__int64)a1);
sub_140061DC0(v10, v9, v6);
throw;
}
}
return v6;
}