//
// MDC2_Final from 0xe6330c to 0xe633ac (160 bytes)
//
// 2 xrefs:
// > sub_E61EB4 @ 0xe61ed8
// > ??> @ 0xb6208
//
// 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 MDC2_Final(_QWORD *a1, __int64 a2)
{
unsigned int v4; // w2
__int64 v6; // x0
v4 = *(_DWORD *)a2;
if ( *(_DWORD *)(a2 + 28) == 2 )
{
v6 = a2 + v4++;
*(_BYTE *)(v6 + 4) = 0x80;
}
else if ( !v4 )
{
*a1 = *(_QWORD *)(a2 + 12);
a1[1] = *(_QWORD *)(a2 + 20);
return 1;
}
memset((void *)(a2 + v4 + 4), 0, 8 - v4);
sub_E63018(a2, a2 + 4, 8u);
*a1 = *(_QWORD *)(a2 + 12);
a1[1] = *(_QWORD *)(a2 + 20);
return 1;
}