1
0
Fork 0

add more fonts

This commit is contained in:
Sen 2025-06-30 18:34:06 +02:00
parent 681bb4dc4e
commit a73901a584
Signed by: sen
GPG key ID: 3AC50A6F47D1B722
6 changed files with 39 additions and 11 deletions

View file

@ -253,8 +253,9 @@ public class Client implements IThreadListener {
}
}
public static class FontFunction implements BoolFunction {
public void apply(BoolVar cv, boolean value) {
public static class FontFunction implements EnumFunction<Font> {
public void apply(EnumVar cv, Font value) {
Font.unload();
Font.load(value);
Client.CLIENT.rescale();
}
@ -473,8 +474,8 @@ public class Client implements IThreadListener {
public Style style = Style.DEFAULT;
@Variable(name = "gui_scroll_lines", category = CVarCategory.GUI, min = 1, max = 10, display = "Scrollbreite", unit = "Zeilen")
public int scrollLines = 3;
@Variable(name = "gui_font_tiny", category = CVarCategory.GUI, display = "Kleine Schrift", callback = FontFunction.class)
public boolean tinyFont = false;
@Variable(name = "gui_font", category = CVarCategory.GUI, display = "Schriftart", callback = FontFunction.class)
public Font font = Font.LARGE;
@Variable(name = "draw_downfall_range", category = CVarCategory.RENDER, min = 0, max = 15, display = "Niederschlag-Radius")
public int downfallRange = 10;
@ -2249,7 +2250,7 @@ public class Client implements IThreadListener {
this.registerDebug();
System.gc();
System.gc();
Font.load(false);
Font.load(Font.LARGE);
GlState.enableBlend();
GlState.blendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
this.initConsole();