add custom font support for all client ui
- new FrosFont renderer: loads ttf/otf from fros/fonts/, rasterizes text to cached textures, falls back to the vanilla font when unset - Font/FontSize settings in ClickGui (fontSize only shows when a font is set); missing files retry automatically every 2s - all gui buttons, panels and hud modules now render through it - handles section codes and styled components (watermark accent color)
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package cc.fros.features.gui;
|
||||
|
||||
import cc.fros.util.render.FrosFont;
|
||||
|
||||
import cc.fros.features.Feature;
|
||||
import cc.fros.features.gui.items.Item;
|
||||
import cc.fros.features.gui.items.buttons.Button;
|
||||
@@ -193,6 +195,6 @@ public class Widget
|
||||
}
|
||||
|
||||
protected void drawString(String text, double x, double y, int color) {
|
||||
context.drawString(mc.font, text, (int) x, (int) y, color);
|
||||
FrosFont.draw(context, text, (int) x, (int) y, color);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user