fix(gui): restore stripped material-icon glyphs and add Misc/Ghost icons
Two related rendering regressions:
1) OldClickGui category headers — the switch in legacy CategoryPanel
only mapped COMBAT..EXPLOIT to icon glyphs 'a'..'e' and fell back
to '?'. The Category enum has WORLD ("Misc") and MISC ("Ghost")
too, so those two headers rendered as a question mark. Extend the
switch with WORLD -> 'f' and MISC -> 'g'.
2) PanelClickGui rendering — several Material Icon PUA codepoints
had been silently stripped to empty strings during earlier source
passes, leaving the panel without bind icon, profile-popup logo /
close button / dropdown arrow, and the number-setting edit icon.
Restore them per Recaf:
- ModuleListPanel bind icon \uE312 (2 sites)
- SettingsPopup logo \uE8B8
- SettingsPopup close button \uE5CD
- SettingsPopup dropdown arrow \uE313
- NumberSettingRenderer edit pen \uE3C9
CategoryBar's 7 category glyphs and PanelClickGui's search icon
already had the correct PUA bytes on disk; they were just
invisible in tooling, so no change there.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -373,7 +373,7 @@ extends Screen {
|
||||
TextGlow.drawBackground(guiGraphics.pose(), searchX, searchY, searchWidth, searchHeight, 8.0f * this.currentScale, alpha);
|
||||
Renderer.renderConsumer((drawContext -> {
|
||||
FontRenderer iconFont = FontPresets.materialIcons(20.0f * this.currentScale);
|
||||
String iconText = "";
|
||||
String iconText = "";
|
||||
float iconX = (float)searchX + 12.0f * this.currentScale;
|
||||
float iconY = (float)searchY + (float)searchHeight / 2.0f + iconFont.getMetrics().capHeight() / 2.0f - 12.0f * this.currentScale;
|
||||
int iconColor = new Color(255, 255, 255, (int)(180.0f * alpha)).getRGB();
|
||||
|
||||
@@ -90,7 +90,8 @@ public class CategoryPanel {
|
||||
case PLAYER -> 'c';
|
||||
case RENDER -> 'd';
|
||||
case EXPLOIT -> 'e';
|
||||
default -> '?';
|
||||
case WORLD -> 'f';
|
||||
case MISC -> 'g';
|
||||
});
|
||||
float iconY = (float)this.y + ((float)this.rowHeight / 2.0f - FontStore.ICON_30.getFontHeight() / 2.0f) + 3.0f;
|
||||
FontStore.ICON_30.drawStringWithShadow(guiGraphics.pose(), iconChar, this.x + 4, iconY, -1);
|
||||
|
||||
@@ -151,12 +151,12 @@ extends ClientBase {
|
||||
}
|
||||
|
||||
static {
|
||||
CATEGORY_ICONS.put(Category.COMBAT, "");
|
||||
CATEGORY_ICONS.put(Category.MOVEMENT, "");
|
||||
CATEGORY_ICONS.put(Category.PLAYER, "");
|
||||
CATEGORY_ICONS.put(Category.RENDER, "");
|
||||
CATEGORY_ICONS.put(Category.EXPLOIT, "");
|
||||
CATEGORY_ICONS.put(Category.WORLD, "");
|
||||
CATEGORY_ICONS.put(Category.MISC, "");
|
||||
CATEGORY_ICONS.put(Category.COMBAT, "");
|
||||
CATEGORY_ICONS.put(Category.MOVEMENT, "");
|
||||
CATEGORY_ICONS.put(Category.PLAYER, "");
|
||||
CATEGORY_ICONS.put(Category.RENDER, "");
|
||||
CATEGORY_ICONS.put(Category.EXPLOIT, "");
|
||||
CATEGORY_ICONS.put(Category.WORLD, "");
|
||||
CATEGORY_ICONS.put(Category.MISC, "");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -249,7 +249,7 @@ extends ClientBase {
|
||||
String bindName = module.getBind().getName();
|
||||
if (!bindName.equalsIgnoreCase("None")) {
|
||||
FontRenderer iconFont = FontPresets.materialIcons(16.0f * scale);
|
||||
String iconText = "";
|
||||
String iconText = "";
|
||||
FontRenderer bindFont = FontPresets.axiformaRegular(16.0f * scale);
|
||||
float bindWidth = GlHelper.getStringWidth(bindName, bindFont);
|
||||
float iconWidth = GlHelper.getStringWidth(iconText, iconFont);
|
||||
@@ -278,7 +278,7 @@ extends ClientBase {
|
||||
int glowByte = (int)(alpha * 0.39215687f * hoverAmount);
|
||||
int glowColor = this.applyAlpha(-3355444, (float)glowByte / 255.0f);
|
||||
FontRenderer iconFont = FontPresets.materialIcons(16.0f * scale);
|
||||
String iconText = "";
|
||||
String iconText = "";
|
||||
FontRenderer bindFont = FontPresets.axiformaRegular(16.0f * scale);
|
||||
float bindWidth = GlHelper.getStringWidth(bindName, bindFont);
|
||||
float iconWidth = GlHelper.getStringWidth(iconText, iconFont);
|
||||
|
||||
@@ -77,7 +77,7 @@ extends ClientBase {
|
||||
private void drawPopupBody(DrawContext drawContext, GuiGraphics guiGraphics, int popupX, int popupY, int mouseX, int mouseY, int popupHeight, int alphaByte, float scale, int popupWidth) {
|
||||
int whiteColor = alphaByte << 24 | 0xFFFFFF;
|
||||
FontRenderer iconFont = FontPresets.materialIcons(18.0f * scale);
|
||||
GlHelper.drawText("", (float)popupX + 15.0f * scale, (float)popupY + 16.0f * scale, iconFont, whiteColor);
|
||||
GlHelper.drawText("", (float)popupX + 15.0f * scale, (float)popupY + 16.0f * scale, iconFont, whiteColor);
|
||||
FontRenderer titleFont = FontPresets.museoSans(22.0f * scale);
|
||||
String title = "ZENLESS.ZONE";
|
||||
float titleWidth = GlHelper.getStringWidth(title, titleFont);
|
||||
@@ -124,7 +124,7 @@ extends ClientBase {
|
||||
int textColor = alphaByte << 24 | r << 16 | g << 8 | b;
|
||||
int glowAlpha = (int)(180.0f * this.closeButtonHoverAlpha * this.openAlpha);
|
||||
int glowColor = new Color(r, g, b, glowAlpha).getRGB();
|
||||
TextGlow.drawGlowText("", btnX, btnY, iconFont, textColor, glowColor, 10.0f * scale);
|
||||
TextGlow.drawGlowText("", btnX, btnY, iconFont, textColor, glowColor, 10.0f * scale);
|
||||
}
|
||||
|
||||
private int drawDropdown(DrawContext drawContext, GuiGraphics guiGraphics, String label, String selectedValue, String[] items, String key, int popupX, int rowY, int mouseX, int mouseY, float openAlpha, float scale, int popupWidth) {
|
||||
@@ -145,7 +145,7 @@ extends ClientBase {
|
||||
float valueY = (float)rowY + (float)dropdownHeaderHeight / 2.0f - valueFont.getMetrics().capHeight() / 2.0f + 3.0f * scale;
|
||||
GlHelper.drawText(selectedValue, valueX, valueY - 2.0f, valueFont, valueColor);
|
||||
FontRenderer arrowFont = FontPresets.materialIcons(18.0f * scale);
|
||||
String arrowIcon = "";
|
||||
String arrowIcon = "";
|
||||
float arrowX = (float)(dropdownX + dropdownWidth) - 18.0f * scale;
|
||||
float arrowY = (float)rowY + (float)dropdownHeaderHeight / 2.0f + arrowFont.getMetrics().capHeight() / 2.0f - 10.5f * scale + 7.0f;
|
||||
GlHelper.drawText(arrowIcon, arrowX, arrowY, arrowFont, valueColor);
|
||||
|
||||
@@ -233,7 +233,7 @@ implements SettingRenderer {
|
||||
int colorTo = -1;
|
||||
int iconColor = RenderUtil.lerpColorHSB(colorFrom, colorTo, progress);
|
||||
FontRenderer iconFont = FontPresets.materialIcons(iconSize);
|
||||
String iconText = "";
|
||||
String iconText = "";
|
||||
float iconTextWidth = GlHelper.getStringWidth(iconText, iconFont);
|
||||
GlyphMetrics iconMetrics = iconFont.getMetrics();
|
||||
float drawX = (float)iconX + ((float)iconSize - iconTextWidth) / 2.0f;
|
||||
|
||||
Reference in New Issue
Block a user