From 1ebf273e3922ea25eb67c7689dfad96997305748 Mon Sep 17 00:00:00 2001 From: ThisIsALegitUsername Date: Thu, 2 Feb 2023 16:29:02 +0000 Subject: [PATCH] Port serverinfo --- src/main/java/dev/resent/module/impl/hud/ArmorHud.java | 2 +- src/main/java/dev/resent/module/impl/hud/ReachDisplay.java | 4 ---- src/main/java/dev/resent/module/impl/hud/ServerInfo.java | 6 ++---- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/src/main/java/dev/resent/module/impl/hud/ArmorHud.java b/src/main/java/dev/resent/module/impl/hud/ArmorHud.java index 434bdc62..8ad48994 100644 --- a/src/main/java/dev/resent/module/impl/hud/ArmorHud.java +++ b/src/main/java/dev/resent/module/impl/hud/ArmorHud.java @@ -9,7 +9,7 @@ import net.minecraft.client.gui.GuiIngame; import net.minecraft.client.gui.ScaledResolution; import net.minecraft.item.ItemStack; -@RenderModule(name = "ArmorHud", category = Category.HUD, x = 15, y = 4, hasSetting = true) +@RenderModule(name = "ArmorHud", category = Category.HUD, x = 20, y = 4, hasSetting = true) public class ArmorHud extends RenderMod { public ScaledResolution sr; diff --git a/src/main/java/dev/resent/module/impl/hud/ReachDisplay.java b/src/main/java/dev/resent/module/impl/hud/ReachDisplay.java index a4e89a7d..abd84ba1 100644 --- a/src/main/java/dev/resent/module/impl/hud/ReachDisplay.java +++ b/src/main/java/dev/resent/module/impl/hud/ReachDisplay.java @@ -15,10 +15,6 @@ public class ReachDisplay extends RenderMod { public static final DecimalFormat df2 = new DecimalFormat("0.00"); public double range; - public ReachDisplay() { - super("ReachDisplay", Category.HUD, 4, 34); - } - public int getWidth() { return mc.fontRendererObj.getStringWidth("[" + df2.format(range) + " Blocks]") + 4; } diff --git a/src/main/java/dev/resent/module/impl/hud/ServerInfo.java b/src/main/java/dev/resent/module/impl/hud/ServerInfo.java index e4a9dd31..69c6ec97 100644 --- a/src/main/java/dev/resent/module/impl/hud/ServerInfo.java +++ b/src/main/java/dev/resent/module/impl/hud/ServerInfo.java @@ -1,15 +1,13 @@ package dev.resent.module.impl.hud; +import dev.resent.annotation.RenderModule; import dev.resent.module.Theme; import dev.resent.module.base.Category; import dev.resent.module.base.RenderMod; +@RenderModule(name = "Server info", category = Category.HUD, x = 4, y = 110) public class ServerInfo extends RenderMod { - public ServerInfo() { - super("Server info", Category.HUD, 4, 44, true); - } - public int getWidth() { return mc.fontRendererObj.getStringWidth(getText()) + 4; }