diff options
| author | BuildTools <james.jenour@protonmail.com> | 2021-02-10 00:31:43 +0800 |
|---|---|---|
| committer | BuildTools <james.jenour@protonmail.com> | 2021-02-10 00:31:43 +0800 |
| commit | e782e847ccc0eadc4d6e58068ed36d30ce233899 (patch) | |
| tree | d7bc8f605889cc9b040e69bd13faef8ab1cd75e3 /src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java | |
| parent | 05ecb9ec0980fbf3eb074deb021d6b06172b8fd2 (diff) | |
| download | notenoughupdates-e782e847ccc0eadc4d6e58068ed36d30ce233899.tar.gz notenoughupdates-e782e847ccc0eadc4d6e58068ed36d30ce233899.tar.bz2 notenoughupdates-e782e847ccc0eadc4d6e58068ed36d30ce233899.zip | |
PRE18
Diffstat (limited to 'src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java')
| -rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java index 65e01a1d..affc86ef 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java @@ -214,16 +214,19 @@ public class FarmingOverlay extends TextOverlay { lineMap.put(2, levelStr.toString()); lineMap.put(3, EnumChatFormatting.AQUA+"Current XP: " + EnumChatFormatting.YELLOW+ format.format(current)); - lineMap.put(4, EnumChatFormatting.AQUA+"Remaining XP: " + EnumChatFormatting.YELLOW+ format.format(remaining)); - - if(xpGainHour < 1000) { - lineMap.put(7, EnumChatFormatting.AQUA+"ETA: "+EnumChatFormatting.YELLOW+ "N/A"); + if(remaining < 0) { + lineMap.put(4, EnumChatFormatting.AQUA+"Remaining XP: " + EnumChatFormatting.YELLOW+ "MAXED!"); + lineMap.put(7, EnumChatFormatting.AQUA+"ETA: "+EnumChatFormatting.YELLOW+ "MAXED!"); } else { - lineMap.put(7, EnumChatFormatting.AQUA+"ETA: "+EnumChatFormatting.YELLOW+ Utils.prettyTime((long)(remaining)*1000*60*60/(long)xpInterp)); + lineMap.put(4, EnumChatFormatting.AQUA+"Remaining XP: " + EnumChatFormatting.YELLOW+ format.format(remaining)); + if(xpGainHour < 1000) { + lineMap.put(7, EnumChatFormatting.AQUA+"ETA: "+EnumChatFormatting.YELLOW+ "N/A"); + } else { + lineMap.put(7, EnumChatFormatting.AQUA+"ETA: "+EnumChatFormatting.YELLOW+ Utils.prettyTime((long)(remaining)*1000*60*60/(long)xpInterp)); + } } - } - + } float yaw = Minecraft.getMinecraft().thePlayer.rotationYawHead; yaw %= 360; |
