diff --git a/src/main/java/com/minelittlepony/PonyConfig.java b/src/main/java/com/minelittlepony/PonyConfig.java index de719cf2..efa6dd23 100644 --- a/src/main/java/com/minelittlepony/PonyConfig.java +++ b/src/main/java/com/minelittlepony/PonyConfig.java @@ -79,7 +79,8 @@ public class PonyConfig extends SensibleConfig implements Exposable { } public void setGlobalScaleFactor(float f) { - globalScaleFactor = Math.round(MathHelper.clamp(f, 0.1F, 1) * 100) / 100F; + globalScaleFactor = Math.round(MathHelper.clamp(f, 0.1F, 3) * 100) / 100F; + showscale = globalScaleFactor != 1; } /** diff --git a/src/main/java/com/minelittlepony/gui/GuiPonySettings.java b/src/main/java/com/minelittlepony/gui/GuiPonySettings.java index 3e3ceea5..b8ebb023 100644 --- a/src/main/java/com/minelittlepony/gui/GuiPonySettings.java +++ b/src/main/java/com/minelittlepony/gui/GuiPonySettings.java @@ -46,15 +46,9 @@ public class GuiPonySettings extends SettingsPanel { })); if (isCtrlKeyDown() && isShiftKeyDown()) { - addButton(new Label(LEFT, row += 30, OPTIONS_PREFIX + "global_scale", -1)); - addButton(new Slider(LEFT, row += 15, 0.1F, 1, config.getGlobalScaleFactor(), (int id, String name, float value) -> { - if (value >= 1) { - return "Scale: Default"; - } - if (value == 0.9F) { - return "Scale: Show Accurate"; - } - return String.format("Scale: %f", value); + addButton(new Label(LEFT, row += 30, "minelp.debug.scale", -1)); + addButton(new Slider(LEFT, row += 15, 0.1F, 3, config.getGlobalScaleFactor(), (int id, String name, float value) -> { + return format("minelp.debug.scale.value", format(describeCurrentScale(value))); }, v -> { config.setGlobalScaleFactor(v); return config.getGlobalScaleFactor(); @@ -79,6 +73,25 @@ public class GuiPonySettings extends SettingsPanel { } } + public String describeCurrentScale(float value) { + if (value >= 3) { + return format("minelp.debug.scale.meg"); + } + if (value == 2) { + return format("minelp.debug.scale.max"); + } + if (value == 1) { + return format("minelp.debug.scale.mid"); + } + if (value == 0.9F) { + return format("minelp.debug.scale.sa"); + } + if (value <= 0.1F) { + return format("minelp.debug.scale.min"); + } + return String.format("%f", value); + } + @Override public void drawContents(int mouseX, int mouseY, float partialTicks) { drawDefaultBackground(); diff --git a/src/main/resources/assets/minelittlepony/lang/en_us.lang b/src/main/resources/assets/minelittlepony/lang/en_us.lang index 6880d3df..2c0e3fc4 100644 --- a/src/main/resources/assets/minelittlepony/lang/en_us.lang +++ b/src/main/resources/assets/minelittlepony/lang/en_us.lang @@ -24,4 +24,11 @@ minelp.mobs.endermen=Ponify endermen minelp.mode.dry=Land pony minelp.mode.wet=Sea pony -minelp.debug.reload_models.message=Reloading pony models... \ No newline at end of file +minelp.debug.reload_models.message=Reloading pony models... +minelp.debug.scale=Scaling Factor +minelp.debug.scale.value=Scale: %s +minelp.debug.scale.meg=Mega +minelp.debug.scale.max=Double +minelp.debug.scale.mid=Default +minelp.debug.scale.sa=Show Accurate +minelp.debug.scale.min=Miniscule \ No newline at end of file