From e1d9f93172f683977f8ca86062e84a3ef6422192 Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Sun, 13 Jun 2021 18:32:13 +1000 Subject: [PATCH] Cheevos: Suffix unofficial achievements in popup --- src/frontend-common/cheevos.cpp | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/frontend-common/cheevos.cpp b/src/frontend-common/cheevos.cpp index 571c87abf..4ae030a36 100644 --- a/src/frontend-common/cheevos.cpp +++ b/src/frontend-common/cheevos.cpp @@ -1101,8 +1101,23 @@ void UnlockAchievement(u32 achievement_id, bool add_notification /* = true*/) DeactivateAchievement(achievement); Log_InfoPrintf("Achievement %s (%u) for game %u unlocked", achievement->title.c_str(), achievement_id, g_game_id); - ImGuiFullscreen::AddNotification(15.0f, achievement->title, achievement->description, - achievement->unlocked_badge_path); + + std::string title; + switch (achievement->category) + { + case AchievementCategory::Local: + title = StringUtil::StdStringFromFormat("%s (Local)", achievement->title.c_str()); + break; + case AchievementCategory::Unofficial: + title = StringUtil::StdStringFromFormat("%s (Unofficial)", achievement->title.c_str()); + break; + case AchievementCategory::Core: + default: + title = achievement->title; + break; + } + + ImGuiFullscreen::AddNotification(15.0f, std::move(title), achievement->description, achievement->unlocked_badge_path); if (s_test_mode) {