From 9dc263f8c53071619860cdc249b4223438aeacc2 Mon Sep 17 00:00:00 2001 From: firef1a Date: Mon, 3 Jun 2024 14:02:38 -0700 Subject: [PATCH] adds vip badge color --- src/main/java/dev/fire/config/Config.java | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/main/java/dev/fire/config/Config.java b/src/main/java/dev/fire/config/Config.java index acc66aa..dc9eef6 100644 --- a/src/main/java/dev/fire/config/Config.java +++ b/src/main/java/dev/fire/config/Config.java @@ -275,7 +275,7 @@ private ConfigCategory.Builder normalChatTags() { OptionGroup.Builder builder = groupBuilder(key,name); builder.option(Option.createBuilder(Color.class) - .name(Text.literal("/whois Color")) + .name(Text.literal("Profile Color")) .description(OptionDescription.createBuilder() .text(Text.literal("Color of your /whois, dictated by the highest paid rank you have. ie: Overlord, Mythic, Emperor, or Noble. ")) .build()) @@ -304,6 +304,20 @@ private ConfigCategory.Builder specialChatTags() { String name = DefaultConfig.newChatTags.get(key).TextContent; OptionGroup.Builder builder = groupBuilder(key,name); + if (Objects.equals(key, "vip")) { + builder.option(Option.createBuilder(Color.class) + .name(Text.literal("Badge Color")) + .description(OptionDescription.createBuilder() + .text(Text.literal("Color of your vip badge ._.")) + .build()) + .binding( + new Color(DefaultConfig.oldChatTags.get(key).TextColor), + () -> new Color(chatTags.get(key).ProfileColor), + opt -> chatTags.get(key).ProfileColor = opt.getRGB() + ) + .controller(ColorControllerBuilder::create) + .build()); + } configBuilder.group(builder.build()); });