From 66cac8350e5c5d6a55ffc2aa92b9591458277860 Mon Sep 17 00:00:00 2001 From: WerWolv Date: Wed, 8 Nov 2023 21:40:27 +0100 Subject: [PATCH] fix: Kaboom achievement not triggering --- plugins/builtin/romfs/lang/en_US.json | 2 ++ plugins/builtin/source/content/welcome_screen.cpp | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/builtin/romfs/lang/en_US.json b/plugins/builtin/romfs/lang/en_US.json index 85d06081e..21b582371 100644 --- a/plugins/builtin/romfs/lang/en_US.json +++ b/plugins/builtin/romfs/lang/en_US.json @@ -5,6 +5,8 @@ "fallback": true, "translations": { "hex.builtin.achievement.starting_out": "Starting out", + "hex.builtin.achievement.starting_out.crash.name": "Yes Rico, Kaboom!", + "hex.builtin.achievement.starting_out.crash.desc": "Crash ImHex for the first time.", "hex.builtin.achievement.starting_out.docs.name": "RTFM", "hex.builtin.achievement.starting_out.docs.desc": "Open the documentation by selecting Help -> Documentation from the menu bar.", "hex.builtin.achievement.starting_out.open_file.name": "The inner workings", diff --git a/plugins/builtin/source/content/welcome_screen.cpp b/plugins/builtin/source/content/welcome_screen.cpp index 38de03365..6ab88a501 100644 --- a/plugins/builtin/source/content/welcome_screen.cpp +++ b/plugins/builtin/source/content/welcome_screen.cpp @@ -542,7 +542,9 @@ namespace hex::plugin::builtin { } if (hasCrashed) { - AchievementManager::unlockAchievement("hex.builtin.achievement.starting_out", "hex.builtin.achievement.starting_out.crash.name"); + TaskManager::doLater([]{ + AchievementManager::unlockAchievement("hex.builtin.achievement.starting_out", "hex.builtin.achievement.starting_out.crash.name"); + }); } }