From 0e95b606e6422982054e2757fa6c15fda187d98c Mon Sep 17 00:00:00 2001 From: Lizbeth Rika Date: Sun, 28 Jun 2015 17:07:47 +0100 Subject: [PATCH] Added a config to change the height of the mana bar for people who use Dual Hotbars or other mods that change the HUD. --- .../java/vazkii/botania/client/core/handler/HUDHandler.java | 3 ++- .../vazkii/botania/common/core/handler/ConfigHandler.java | 4 ++++ src/main/resources/assets/botania/lang/en_US.lang | 1 + 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/main/java/vazkii/botania/client/core/handler/HUDHandler.java b/src/main/java/vazkii/botania/client/core/handler/HUDHandler.java index 08cb55b79..b1b968431 100644 --- a/src/main/java/vazkii/botania/client/core/handler/HUDHandler.java +++ b/src/main/java/vazkii/botania/client/core/handler/HUDHandler.java @@ -54,6 +54,7 @@ import vazkii.botania.common.block.ModBlocks; import vazkii.botania.common.block.tile.corporea.TileCorporeaCrystalCube; import vazkii.botania.common.block.tile.corporea.TileCorporeaIndex; import vazkii.botania.common.block.tile.mana.TilePool; +import vazkii.botania.common.core.handler.ConfigHandler; import vazkii.botania.common.item.ItemCraftingHalo; import vazkii.botania.common.item.ItemTwigWand; import vazkii.botania.common.item.ModItems; @@ -203,7 +204,7 @@ public final class HUDHandler { Minecraft mc = Minecraft.getMinecraft(); int width = 182; int x = res.getScaledWidth() / 2 - width / 2; - int y = res.getScaledHeight() - 29; + int y = res.getScaledHeight() - ConfigHandler.manaBarHeight; if(!hasCreative) { if(totalMaxMana == 0) diff --git a/src/main/java/vazkii/botania/common/core/handler/ConfigHandler.java b/src/main/java/vazkii/botania/common/core/handler/ConfigHandler.java index 23de176a0..527993f9d 100644 --- a/src/main/java/vazkii/botania/common/core/handler/ConfigHandler.java +++ b/src/main/java/vazkii/botania/common/core/handler/ConfigHandler.java @@ -42,6 +42,7 @@ public final class ConfigHandler { public static boolean useVanillaParticleLimiter = true; public static boolean silentSpreaders = false; public static boolean renderBaubles = true; + public static int manaBarHeight = 29; public static boolean altFlowerTextures = false; public static boolean matrixMode = false; @@ -134,6 +135,9 @@ public final class ConfigHandler { desc = "Set this to false to disable rendering of baubles in the player."; renderBaubles = loadPropBool("baubleRender.enabled", desc, renderBaubles); + desc = "The height of the mana display bar in above the XP bar. You can change this if you have a mod that changes where the XP bar is."; + manaBarHeight = loadPropInt("manaBar.height", desc, manaBarHeight); + desc = "Set this to true to use alternate flower textures by Futureazoo, not all flowers are textured. http://redd.it/2b3o3f"; altFlowerTextures = loadPropBool("flowerTextures.alt", desc, altFlowerTextures); diff --git a/src/main/resources/assets/botania/lang/en_US.lang b/src/main/resources/assets/botania/lang/en_US.lang index 568005df4..1739eba67 100644 --- a/src/main/resources/assets/botania/lang/en_US.lang +++ b/src/main/resources/assets/botania/lang/en_US.lang @@ -268,6 +268,7 @@ flowerParticles.frequency=Flower Particle Frequency lexicon.enable.rotatingItems=Lexicon Rotating Items lexicon.enable.justifiedText=Lexicon Justified Text lexicon.render.3D=3D Lexicon Render +manaBar.height=Mana Bar Height powerSystem.subtle=Use Subtle Power System pylonModel.old=Use Old Pylon Model elfPortal.particles.enabled=Enable Portal Particles