From 850f5a3e1259094432420446470f09fa24c12b9e Mon Sep 17 00:00:00 2001 From: Snaiker Date: Wed, 13 Apr 2022 05:47:03 +0100 Subject: [PATCH] Fix --- .../habbo/habbohotel/achievements/AchievementManager.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/eu/habbo/habbohotel/achievements/AchievementManager.java b/src/main/java/com/eu/habbo/habbohotel/achievements/AchievementManager.java index 725ab2a1..8490d30f 100644 --- a/src/main/java/com/eu/habbo/habbohotel/achievements/AchievementManager.java +++ b/src/main/java/com/eu/habbo/habbohotel/achievements/AchievementManager.java @@ -148,14 +148,14 @@ public class AchievementManager { String newBadgCode = "ACH_" + achievement.name + newLevel.level; - if (habbo.getInventory().getBadgesComponent().hasBadge(newBadgCode)) - return; - if (badge != null) { badge.setCode(newBadgCode); badge.needsInsert(false); badge.needsUpdate(true); } else { + if (habbo.getInventory().getBadgesComponent().hasBadge(newBadgCode)) + return; + badge = new HabboBadge(0, newBadgCode, 0, habbo); habbo.getClient().sendResponse(new AddUserBadgeComposer(badge)); badge.needsInsert(true);