diff options
Diffstat (limited to 'src/main')
-rw-r--r-- | src/main/java/me/xmrvizzy/skyblocker/skyblock/FancyStatusBars.java | 9 | ||||
-rw-r--r-- | src/main/resources/assets/skyblocker/textures/gui/bars.png | bin | 1212 -> 6756 bytes |
2 files changed, 6 insertions, 3 deletions
diff --git a/src/main/java/me/xmrvizzy/skyblocker/skyblock/FancyStatusBars.java b/src/main/java/me/xmrvizzy/skyblocker/skyblock/FancyStatusBars.java index 1c86e733..e5b13032 100644 --- a/src/main/java/me/xmrvizzy/skyblocker/skyblock/FancyStatusBars.java +++ b/src/main/java/me/xmrvizzy/skyblocker/skyblock/FancyStatusBars.java @@ -48,9 +48,8 @@ public class FancyStatusBars extends DrawableHelper { int top = scaledHeight - 35; int hpFillWidth = (int) (health.getFillLevel() * 33.0F); - if (hpFillWidth > 33) hpFillWidth = 33; + int hpOverflowWidth = (int) (health.getOverflow() * 33.0F); int manaFillWidth = (int) (mana.getFillLevel() * 33.0F); - if (manaFillWidth > 33) manaFillWidth = 33; int xp = (int) (client.player.experienceProgress * 33.0F); // Icons @@ -69,6 +68,7 @@ public class FancyStatusBars extends DrawableHelper { // Progress Bars this.drawTexture(matrices, left + 10, top + 1, 0, 16, hpFillWidth, 7); + this.drawTexture(matrices, left + 10, top + 1, 0, 44, hpOverflowWidth, 7); this.drawTexture(matrices, left + 55, top + 1, 0, 23, manaFillWidth, 7); this.drawTexture(matrices, left + 102, top + 1, 0, 30, 33, 7); this.drawTexture(matrices, left + 149, top + 1, 0, 37, xp, 7); @@ -109,7 +109,10 @@ public class FancyStatusBars extends DrawableHelper { return value; } public double getFillLevel() { - return ((double)value)/((double)max); + return Math.min(((double)value)/((double)max), 1); + } + public double getOverflow() { + return Math.max(((double)value)/((double)max) - 1, 0); } } }
\ No newline at end of file diff --git a/src/main/resources/assets/skyblocker/textures/gui/bars.png b/src/main/resources/assets/skyblocker/textures/gui/bars.png Binary files differindex 0b700024..d3fc95b1 100644 --- a/src/main/resources/assets/skyblocker/textures/gui/bars.png +++ b/src/main/resources/assets/skyblocker/textures/gui/bars.png |