Merge branch 'v0.4.0' into v0.4.0-1.21.3

This commit is contained in:
KawaiiZenbo 2024-11-09 18:07:54 -08:00 committed by GitHub
commit 8abcd7341e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
40 changed files with 233 additions and 183 deletions

View file

@ -1,5 +1,6 @@
package me.kawaiizenbo.moonlight.ui.hud.editor;
import me.kawaiizenbo.moonlight.Moonlight;
import me.kawaiizenbo.moonlight.ui.hud.HUDModule;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.font.TextRenderer;
@ -23,8 +24,8 @@ public class HUDModuleButton
{
this.x = x;
this.y = y;
drawContext.fill(x, y, x + width, y + height, hovered(mouseX, mouseY) ? 0xFF333333 : 0xFF222222);
drawContext.drawText(textRenderer, module.name, x+2, y+2, module.enabled ? 0x55FFFF : 0xFFFFFF, false);
drawContext.fill(x, y, x + width, y + height, hovered(mouseX, mouseY) ? Moonlight.THEME.hover.getRGB() : Moonlight.THEME.background.getRGB());
drawContext.drawText(textRenderer, module.name, x+2, y+2, module.enabled ? Moonlight.THEME.accent.getRGB() : Moonlight.THEME.text.getRGB(), false);
if (!module.settings.isEmpty()) drawContext.drawGuiTexture(RenderLayer::getGuiTextured, Identifier.of("moonlight", "settings"), x+width-12, y, 12, 12);
}