Make old opaque theme colors translucent once

Configs saved before 0.1.3 hold the old default and preset background
and primary colors fully opaque, so glass didn't show for anyone
updating. On a config without Menu blur (new in 0.1.3), colors that are
an old default or preset get their translucent alpha; colors players
picked stay as they are.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-09-28 23:05:27 +02:00
co-authored by claude
parent 7d0bfd26c9
commit 69c830d466
3 changed files with 45 additions and 8 deletions
@@ -28,6 +28,9 @@ public class Config {
public static FloatProperty titleScale = guiScale();
public static FloatProperty menuScale = guiScale();
public static FloatProperty hudMenuScale = guiScale();
/** Added in 0.1.3, so a config without it was saved by an older version */
static final String MENU_BLUR = "Menu blur";
public static KeybindingProperty openEmoteWheel = Property.keybinding(GLFWProvider.GLFW_KEY_B);
private static FloatProperty guiScale() {
@@ -57,7 +60,7 @@ public class Config {
config.property("Cloak Physics", cloakPhysics, "Let cloaks swing as you move");
config.property("Stagger Animations", stagger, "Animate list items one after another");
config.property("World blur", backgroundBlur, "How much the world or panorama behind Saturn's screens is blurred");
config.property("Menu blur", menuBlur, "How much the game is blurred through translucent menus");
config.property(MENU_BLUR, menuBlur, "How much the game is blurred through translucent menus");
config.property("Widget blur", widgetBlur, "How much the game is blurred through translucent buttons and the dock");
config.property("Title screen scale", titleScale, "How big the title screen is, relative to Minecraft's GUI scale");
config.property("Menu scale", menuScale, "How big the mods, settings and cosmetics menus are, relative to Minecraft's GUI scale");