Added screen text font scale config option.
This commit is contained in:
@ -39,7 +39,7 @@ public class GuiRenderTickMixin {
|
|||||||
|
|
||||||
// Render player state text
|
// Render player state text
|
||||||
poseStack.pushPose();
|
poseStack.pushPose();
|
||||||
poseStack.scale(3, 3, 3);
|
poseStack.scale(Config.Client.GUI_SCREEN_TEXT_SCALE.get(), Config.Client.GUI_SCREEN_TEXT_SCALE.get(), Config.Client.GUI_SCREEN_TEXT_SCALE.get());
|
||||||
|
|
||||||
// Check if we should draw the state
|
// Check if we should draw the state
|
||||||
if (Proxy.Client.getPlayerState() != null && !Proxy.Client.getPlayerState().equals(ProtectedPlayer.State.ACTIVE)) {
|
if (Proxy.Client.getPlayerState() != null && !Proxy.Client.getPlayerState().equals(ProtectedPlayer.State.ACTIVE)) {
|
||||||
|
|||||||
@ -34,12 +34,16 @@ public final class Config {
|
|||||||
|
|
||||||
public static class Client {
|
public static class Client {
|
||||||
public static ForgeConfigSpec.BooleanValue GUI_SCREEN_TEXT_ENABLED;
|
public static ForgeConfigSpec.BooleanValue GUI_SCREEN_TEXT_ENABLED;
|
||||||
|
public static ForgeConfigSpec.IntValue GUI_SCREEN_TEXT_SCALE;
|
||||||
|
|
||||||
Client(ForgeConfigSpec.Builder builder) {
|
Client(ForgeConfigSpec.Builder builder) {
|
||||||
builder.comment("GUI settings.").push("GUI");
|
builder.comment("GUI settings.").push("GUI");
|
||||||
GUI_SCREEN_TEXT_ENABLED = builder
|
GUI_SCREEN_TEXT_ENABLED = builder
|
||||||
.comment("Whether current protection status is displayed as text on screen.")
|
.comment("Whether current protection status is displayed as text on screen.")
|
||||||
.define("guiScreenTextEnabled", true);
|
.define("guiScreenTextEnabled", true);
|
||||||
|
GUI_SCREEN_TEXT_SCALE = builder
|
||||||
|
.comment("Controls the text font size.")
|
||||||
|
.defineInRange("guiScreenTextScale", 3, 1, 10);
|
||||||
builder.pop();
|
builder.pop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user