//
// GameManager::completedAchievement from 0x325bc8 to 0x325c46 (126 bytes)
//
// 2 xrefs:
// > GameManager::reportAchievementWithID @ 0x325c84
// > GameManager::verifyAchievementUnlocks @ 0x32626a
//
// 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
//
void __fastcall GameManager::completedAchievement(GameManager *a1, const char **a2)
{
const char *v4; // r0
int v5; // r5
IconType v6; // r0
int v7; // [sp+0h] [bp-14h] BYREF
int v8; // [sp+4h] [bp-10h] BYREF
const char *v9; // [sp+8h] [bp-Ch] BYREF
v4 = *a2;
v7 = 0;
v8 = 0;
PlatformToolbox::logEvent(v4);
sub_775C20(&v9, a2);
GameManager::getUnlockForAchievement((int)a1, &v9, &v7, &v8);
sub_774008(&v9);
if ( v8 )
{
if ( (unsigned int)(v8 - 2) > 1 )
{
v5 = v7;
v6 = GameManager::unlockTypeToIconType(a1, v8);
GameManager::unlockIcon(a1, v5, v6);
}
else
{
GameManager::unlockColor(a1, v7, (UnlockType)v8);
}
}
}