From 5058ffcdd4fba3f1f19d8e4e32b4d0137b9a61ba Mon Sep 17 00:00:00 2001 From: TudbuT Date: Tue, 18 Jun 2024 17:42:02 +0200 Subject: [PATCH] fix a bug in notification positioning --- .../de/com/baseband/client/feature/modules/render/HUD.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Client/src/main/java/de/com/baseband/client/feature/modules/render/HUD.java b/Client/src/main/java/de/com/baseband/client/feature/modules/render/HUD.java index 2e43a93..278e675 100644 --- a/Client/src/main/java/de/com/baseband/client/feature/modules/render/HUD.java +++ b/Client/src/main/java/de/com/baseband/client/feature/modules/render/HUD.java @@ -238,7 +238,7 @@ public class HUD extends Feature { for (int i = 0; i < renderFeatures.length; i++) { Feature f = renderFeatures[i]; mc.fontRenderer.drawString(f.getHUDText(), 3, yl, getColor(f, i), textShadow); - yl = yl + mc.fontRenderer.FONT_HEIGHT; + yl += mc.fontRenderer.FONT_HEIGHT; } yl += 3; @@ -264,6 +264,8 @@ public class HUD extends Feature { TextSplitter.drawString(infoString, x, yr, theme.getGreenColor(), textShadow, textMatchOrientation); yr += TextSplitter.getStringHeight(infoString) + 3; } + if(infoLoc == InfoLocation.BottomRight) + yr = 2; renderNotifications(yl, yr); } @@ -272,7 +274,7 @@ public class HUD extends Feature { if(notificationRenderer == null) return; int y = nLocation == NotificationRender.NotificationLocation.Left ? yl : yr; - notificationRenderer.begin(infoLoc == InfoLocation.BottomRight ? 2 : y); + notificationRenderer.begin(y); for (int i = notifs.size() - 1; i >= 0; i--) { notificationRenderer.renderNotification(notifs.get(i)); }