2021-03-21 20:17:31 +01:00
|
|
|
package fr.pandacube.lib.core.chat;
|
2020-11-02 23:23:41 +01:00
|
|
|
|
|
|
|
import java.awt.Color;
|
2021-07-09 00:27:59 +02:00
|
|
|
import java.util.Objects;
|
2021-03-21 20:17:31 +01:00
|
|
|
import java.util.function.Supplier;
|
2021-07-09 00:27:59 +02:00
|
|
|
import java.util.function.UnaryOperator;
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
import org.checkerframework.checker.nullness.qual.NonNull;
|
|
|
|
|
|
|
|
import net.kyori.adventure.key.Key;
|
|
|
|
import net.kyori.adventure.text.Component;
|
|
|
|
import net.kyori.adventure.text.ComponentLike;
|
|
|
|
import net.kyori.adventure.text.TextComponent;
|
|
|
|
import net.kyori.adventure.text.event.ClickEvent;
|
|
|
|
import net.kyori.adventure.text.event.HoverEvent;
|
|
|
|
import net.kyori.adventure.text.event.HoverEventSource;
|
|
|
|
import net.kyori.adventure.text.format.Style;
|
|
|
|
import net.kyori.adventure.text.format.TextColor;
|
|
|
|
import net.kyori.adventure.text.format.TextDecoration;
|
|
|
|
import net.kyori.adventure.text.format.TextDecoration.State;
|
|
|
|
import net.kyori.adventure.text.serializer.bungeecord.BungeeComponentSerializer;
|
|
|
|
import net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer;
|
2021-07-11 16:14:47 +02:00
|
|
|
import net.kyori.adventure.text.serializer.plain.PlainComponentSerializer;
|
2020-11-02 23:23:41 +01:00
|
|
|
import net.md_5.bungee.api.ChatColor;
|
|
|
|
import net.md_5.bungee.api.chat.BaseComponent;
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public abstract class Chat extends ChatStatic implements HoverEventSource<Component>, ComponentLike {
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
protected Component component;
|
2020-11-02 23:23:41 +01:00
|
|
|
protected boolean console = false;
|
|
|
|
|
2021-07-11 16:14:47 +02:00
|
|
|
protected Chat(Component c) {
|
2021-07-09 00:27:59 +02:00
|
|
|
Objects.requireNonNull(c, "Provided component must not be null");
|
2020-11-02 23:23:41 +01:00
|
|
|
component = c;
|
|
|
|
}
|
|
|
|
|
|
|
|
public BaseComponent get() {
|
2021-07-09 00:27:59 +02:00
|
|
|
return toBungee(component);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Component getAdv() {
|
2020-11-02 23:23:41 +01:00
|
|
|
return component;
|
|
|
|
}
|
|
|
|
|
|
|
|
public BaseComponent[] getAsArray() {
|
2021-07-09 00:27:59 +02:00
|
|
|
return toBungeeArray(component);
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
public String getLegacyText() {
|
2021-07-09 00:27:59 +02:00
|
|
|
return LegacyComponentSerializer.legacySection().serializeOr(component, "");
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|
|
|
|
|
2021-07-11 16:14:47 +02:00
|
|
|
public String getPlainText() {
|
|
|
|
return PlainComponentSerializer.plain().serializeOr(component, "");
|
|
|
|
}
|
|
|
|
|
2020-11-02 23:23:41 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
|
2020-11-02 23:23:41 +01:00
|
|
|
public Chat then(BaseComponent subComponent) {
|
2021-07-09 00:27:59 +02:00
|
|
|
return then(toAdventure(subComponent));
|
|
|
|
}
|
|
|
|
public Chat then(Chat comp) {
|
|
|
|
return then(comp.getAdv());
|
|
|
|
}
|
|
|
|
public Chat then(BaseComponent[] components) {
|
|
|
|
return then(toAdventure(components));
|
|
|
|
}
|
|
|
|
public Chat then(Component comp) {
|
|
|
|
if (comp instanceof TextComponent) {
|
|
|
|
TextComponent txtComp = (TextComponent) comp;
|
|
|
|
if (!txtComp.hasStyling() && (txtComp.content() == null || txtComp.content().isEmpty())) {
|
2020-11-02 23:23:41 +01:00
|
|
|
// no need to add the provided component to the current component.
|
|
|
|
// but eventual child component must be added
|
2021-07-09 00:27:59 +02:00
|
|
|
if (txtComp.children() != null && !txtComp.children().isEmpty()) {
|
|
|
|
for (Component child : txtComp.children())
|
2020-11-02 23:23:41 +01:00
|
|
|
then(child);
|
|
|
|
}
|
|
|
|
return this;
|
|
|
|
}
|
|
|
|
}
|
2021-07-09 00:27:59 +02:00
|
|
|
component.append(comp);
|
2020-11-02 23:23:41 +01:00
|
|
|
return this;
|
|
|
|
}
|
|
|
|
|
|
|
|
public Chat thenText(Object plainText) { return then(text(plainText)); }
|
|
|
|
|
|
|
|
public Chat thenInfo(Object plainText) { return then(infoText(plainText)); }
|
|
|
|
|
|
|
|
public Chat thenSuccess(Object plainText) { return then(successText(plainText)); }
|
|
|
|
|
|
|
|
public Chat thenFailure(Object plainText) { return then(failureText(plainText)); }
|
|
|
|
|
|
|
|
public Chat thenData(Object plainText) { return then(dataText(plainText)); }
|
|
|
|
|
|
|
|
public Chat thenDecoration(Object plainText) { return then(decorationText(plainText)); }
|
|
|
|
|
|
|
|
public Chat thenPlayerName(String legacyText) { return then(playerNameText(legacyText)); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public Chat thenNewLine() { return then(Component.newline()); }
|
2020-11-02 23:23:41 +01:00
|
|
|
|
|
|
|
public Chat thenLegacyText(Object legacyText) { return then(legacyText(legacyText)); }
|
|
|
|
|
|
|
|
public Chat thenTranslation(String key, Object... with) { return then(translation(key, with)); }
|
|
|
|
|
|
|
|
public Chat thenKeyBind(String key) { return then(keybind(key)); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public Chat thenScore(String name, String objective) { return then(score(name, objective)); }
|
2020-11-02 23:23:41 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public Chat thenURLLink(Chat inner, String url, Chat hover) { return then(ChatUtil.createURLLink(inner, url, hover)); }
|
|
|
|
public Chat thenURLLink(Chat inner, String url) { return thenURLLink(inner, url, null); }
|
|
|
|
public Chat thenURLLink(String url, Chat hover) { return thenURLLink(text(url), url, hover); }
|
|
|
|
public Chat thenURLLink(String url) { return thenURLLink(text(url), url); }
|
|
|
|
|
|
|
|
public Chat thenCommandLink(Chat inner, String cmdWithSlash, Chat hover) { return then(ChatUtil.createCommandLink(inner, cmdWithSlash, hover)); }
|
|
|
|
public Chat thenCommandLink(Chat inner, String cmdWithSlash) { return thenCommandLink(inner, cmdWithSlash, null); }
|
|
|
|
public Chat thenCommandLink(String cmdWithSlash, Chat hover) { return thenCommandLink(text(cmdWithSlash), cmdWithSlash, hover); }
|
|
|
|
public Chat thenCommandLink(String cmdWithSlash) { return thenCommandLink(text(cmdWithSlash), cmdWithSlash); }
|
|
|
|
|
|
|
|
public Chat thenCommandSuggest(Chat inner, String cmdWithSlash, Chat hover) { return then(ChatUtil.createCommandSuggest(inner, cmdWithSlash, hover)); }
|
|
|
|
public Chat thenCommandSuggest(Chat inner, String cmdWithSlash) { return thenCommandSuggest(inner, cmdWithSlash, null); }
|
|
|
|
public Chat thenCommandSuggest(String cmdWithSlash, Chat hover) { return thenCommandSuggest(text(cmdWithSlash), cmdWithSlash, hover); }
|
|
|
|
public Chat thenCommandSuggest(String cmdWithSlash) { return thenCommandSuggest(text(cmdWithSlash), cmdWithSlash); }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenEmptyCharLine() {
|
2021-03-21 20:17:31 +01:00
|
|
|
return then(ChatUtil.emptyLine(config.decorationChar, config.decorationColor, console));
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color,
|
|
|
|
* and with the provided Chat left aligned on the line, default to the decoration color, and surrounded with 1 space on each side.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenLeftTextCharLine(Chat leftText) {
|
2021-07-11 16:14:47 +02:00
|
|
|
return then(ChatUtil.leftText(chat().decorationColor().thenText(" ").then(leftText).thenText(" "), config.decorationChar,
|
2021-03-21 20:17:31 +01:00
|
|
|
config.decorationColor, config.nbCharMargin, console));
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color,
|
|
|
|
* and with the provided component left aligned on the line, default to the decoration color, and surrounded with 1 space on each side.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenLeftTextCharLine(BaseComponent leftText) {
|
|
|
|
return thenLeftTextCharLine(chatComponent(leftText));
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color,
|
|
|
|
* and with the provided Chat right aligned on the line, default to the decoration color, and surrounded with 1 space on each side.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenRightTextCharLine(Chat rightText) {
|
2021-07-11 16:14:47 +02:00
|
|
|
return then(ChatUtil.rightText(chat().decorationColor().thenText(" ").then(rightText).thenText(" "), config.decorationChar,
|
2021-03-21 20:17:31 +01:00
|
|
|
config.decorationColor, config.nbCharMargin, console));
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color,
|
|
|
|
* and with the provided component right aligned on the line, default to the decoration color, and surrounded with 1 space on each side.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenRightTextCharLine(BaseComponent leftText) {
|
|
|
|
return thenRightTextCharLine(chatComponent(leftText));
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color,
|
|
|
|
* and with the provided Chat centered on the line, default to the decoration color, and surrounded with 1 space on each side.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenCenterTextCharLine(Chat centerText) {
|
2021-07-11 16:14:47 +02:00
|
|
|
return then(ChatUtil.centerText(chat().decorationColor().thenText(" ").then(centerText).thenText(" "), config.decorationChar,
|
2021-03-21 20:17:31 +01:00
|
|
|
config.decorationColor, console));
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|
|
|
|
/**
|
|
|
|
* Draws a full line with the default decoration char, colored with the default decoration color,
|
|
|
|
* and with the provided component centered on the line, default to the decoration color, and surrounded with 1 space on each side.
|
|
|
|
* @return this, for method chaining
|
|
|
|
*/
|
|
|
|
public Chat thenCenterTextCharLine(BaseComponent leftText) {
|
|
|
|
return thenCenterTextCharLine(chatComponent(leftText));
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public static class FormatableChat extends Chat {
|
2021-07-11 16:14:47 +02:00
|
|
|
/* package */ FormatableChat(Component c) {
|
2020-11-02 23:23:41 +01:00
|
|
|
super(c);
|
|
|
|
}
|
|
|
|
|
|
|
|
public FormatableChat console(boolean c) { console = c; return this; }
|
2021-07-09 00:27:59 +02:00
|
|
|
|
|
|
|
public FormatableChat color(TextColor c) { component.color(c); return this; }
|
|
|
|
public FormatableChat color(ChatColor c) { return color(TextColor.color(c.getColor().getRGB())); }
|
2021-07-11 16:14:47 +02:00
|
|
|
public FormatableChat color(Color c) { return color(TextColor.color(c.getRGB())); }
|
2020-11-02 23:23:41 +01:00
|
|
|
public FormatableChat color(String c) { return color(ChatColor.of(c)); }
|
|
|
|
|
|
|
|
public FormatableChat black() { return color(ChatColor.BLACK); }
|
|
|
|
public FormatableChat darkBlue() { return color(ChatColor.DARK_BLUE); }
|
|
|
|
public FormatableChat darkGreen() { return color(ChatColor.DARK_GREEN); }
|
|
|
|
public FormatableChat darkAqua() { return color(ChatColor.DARK_AQUA); }
|
|
|
|
public FormatableChat darkRed() { return color(ChatColor.DARK_RED); }
|
|
|
|
public FormatableChat darkPurple() { return color(ChatColor.DARK_PURPLE); }
|
|
|
|
public FormatableChat gold() { return color(ChatColor.GOLD); }
|
|
|
|
public FormatableChat gray() { return color(ChatColor.GRAY); }
|
|
|
|
public FormatableChat darkGray() { return color(ChatColor.DARK_GRAY); }
|
|
|
|
public FormatableChat blue() { return color(ChatColor.BLUE); }
|
|
|
|
public FormatableChat green() { return color(ChatColor.GREEN); }
|
|
|
|
public FormatableChat aqua() { return color(ChatColor.AQUA); }
|
|
|
|
public FormatableChat red() { return color(ChatColor.RED); }
|
|
|
|
public FormatableChat lightPurple() { return color(ChatColor.LIGHT_PURPLE); }
|
|
|
|
public FormatableChat yellow() { return color(ChatColor.YELLOW); }
|
|
|
|
public FormatableChat white() { return color(ChatColor.WHITE); }
|
|
|
|
|
2021-03-21 20:17:31 +01:00
|
|
|
public FormatableChat successColor() { return color(config.successColor); }
|
|
|
|
public FormatableChat failureColor() { return color(config.failureColor); }
|
|
|
|
public FormatableChat infoColor() { return color(config.infoColor); }
|
|
|
|
public FormatableChat dataColor() { return color(config.dataColor); }
|
|
|
|
public FormatableChat decorationColor() { return color(config.decorationColor); }
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
private FormatableChat setStyle(UnaryOperator<Style> styleOp) {
|
|
|
|
component.style(styleOp.apply(component.style()));
|
|
|
|
return this;
|
|
|
|
}
|
|
|
|
private FormatableChat setDecoration(TextDecoration deco, Boolean state) {
|
|
|
|
return setStyle(s -> s.decoration(deco, State.byBoolean(state)));
|
|
|
|
}
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat font(Key f) { return setStyle(s -> s.font(f)); }
|
|
|
|
|
|
|
|
public FormatableChat bold(Boolean b) { return setDecoration(TextDecoration.BOLD, b); }
|
2020-11-02 23:23:41 +01:00
|
|
|
public FormatableChat bold() { return bold(true); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat italic(Boolean i) { return setDecoration(TextDecoration.ITALIC, i); }
|
2020-11-02 23:23:41 +01:00
|
|
|
public FormatableChat italic() { return italic(true); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat underlined(Boolean u) { return setDecoration(TextDecoration.UNDERLINED, u); }
|
2020-11-02 23:23:41 +01:00
|
|
|
public FormatableChat underlined() { return underlined(true); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat strikethrough(Boolean s) { return setDecoration(TextDecoration.STRIKETHROUGH, s); }
|
2020-11-02 23:23:41 +01:00
|
|
|
public FormatableChat strikethrough() { return strikethrough(true); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat obfuscated(Boolean o) { return setDecoration(TextDecoration.OBFUSCATED, o); }
|
2020-11-02 23:23:41 +01:00
|
|
|
public FormatableChat obfuscated() { return obfuscated(true); }
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat shiftClickInsertion(String i) { component.insertion(i); return this; }
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
private FormatableChat click(ClickEvent e) { component.clickEvent(e); return this; }
|
|
|
|
public FormatableChat clickCommand(String cmdWithSlash) { return click(ClickEvent.runCommand(cmdWithSlash)); }
|
|
|
|
public FormatableChat clickSuggest(String cmdWithSlash) { return click(ClickEvent.suggestCommand(cmdWithSlash)); }
|
|
|
|
public FormatableChat clickClipboard(String value) { return click(ClickEvent.copyToClipboard(value)); }
|
|
|
|
public FormatableChat clickURL(String url) { return click(ClickEvent.openUrl(url)); }
|
|
|
|
public FormatableChat clickBookPage(int page) { return click(ClickEvent.changePage(page)); }
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
public FormatableChat hover(HoverEventSource<?> e) { component.hoverEvent(e); return this; }
|
|
|
|
public FormatableChat hover(Chat v) { return hover(v.getAdv()); }
|
|
|
|
public FormatableChat hover(BaseComponent v) { return hover(toAdventure(v)); }
|
|
|
|
public FormatableChat hover(BaseComponent[] v) { return hover(toAdventure(v)); }
|
|
|
|
public FormatableChat hover(String legacyText) { return hover(legacyText(legacyText)); }
|
2020-11-02 23:23:41 +01:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
@Override
|
|
|
|
public @NonNull HoverEvent<Component> asHoverEvent(@NonNull UnaryOperator<Component> op) {
|
|
|
|
return HoverEvent.showText(op.apply(getAdv()));
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public @NonNull Component asComponent() {
|
|
|
|
return getAdv();
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-11-02 23:23:41 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* package */ static Object[] filterChatToBaseComponent(Object[] values) {
|
|
|
|
if (values == null)
|
|
|
|
return null;
|
|
|
|
for (int i = 0; i < values.length; i++) {
|
|
|
|
Object v = values[i];
|
|
|
|
if (v instanceof Chat)
|
|
|
|
values[i] = ((Chat) v).get();
|
|
|
|
}
|
|
|
|
return values;
|
|
|
|
}
|
2021-07-09 00:27:59 +02:00
|
|
|
|
|
|
|
/* package */ static ComponentLike[] filterObjToComponentLike(Object[] values) {
|
|
|
|
if (values == null)
|
|
|
|
return null;
|
|
|
|
ComponentLike[] ret = new ComponentLike[values.length];
|
|
|
|
for (int i = 0; i < values.length; i++) {
|
|
|
|
Object v = values[i];
|
|
|
|
if (v instanceof Chat)
|
|
|
|
ret[i] = ((Chat) v).getAdv();
|
|
|
|
else if (v instanceof BaseComponent[])
|
|
|
|
ret[i] = toAdventure((BaseComponent[]) v);
|
|
|
|
else if (v instanceof BaseComponent)
|
|
|
|
ret[i] = toAdventure((BaseComponent) v);
|
|
|
|
else
|
|
|
|
ret[i] = Component.text(Objects.toString(v));
|
|
|
|
}
|
|
|
|
return ret;
|
|
|
|
}
|
2020-11-02 23:23:41 +01:00
|
|
|
|
2021-07-09 00:27:59 +02:00
|
|
|
|
2021-07-11 16:14:47 +02:00
|
|
|
public static Component toAdventure(BaseComponent[] components) {
|
2021-07-09 00:27:59 +02:00
|
|
|
return BungeeComponentSerializer.get().deserialize(components);
|
|
|
|
}
|
2021-07-11 16:14:47 +02:00
|
|
|
public static Component toAdventure(BaseComponent component) {
|
2021-07-09 00:27:59 +02:00
|
|
|
return toAdventure(new BaseComponent[] { component });
|
|
|
|
}
|
2021-03-21 20:17:31 +01:00
|
|
|
|
2021-07-11 16:14:47 +02:00
|
|
|
public static BaseComponent[] toBungeeArray(Component component) {
|
2021-07-09 00:27:59 +02:00
|
|
|
return BungeeComponentSerializer.get().serialize(component);
|
|
|
|
}
|
2021-07-11 16:14:47 +02:00
|
|
|
public static BaseComponent toBungee(Component component) {
|
2021-07-09 00:27:59 +02:00
|
|
|
BaseComponent[] arr = toBungeeArray(component);
|
|
|
|
return arr.length == 1 ? arr[0] : new net.md_5.bungee.api.chat.TextComponent(arr);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public static Chat italicFalseIfNotSet(Chat c) {
|
|
|
|
if (c instanceof FormatableChat) {
|
|
|
|
if (c.component.style().decoration(TextDecoration.ITALIC) == State.NOT_SET)
|
|
|
|
((FormatableChat) c).italic(false);
|
|
|
|
}
|
|
|
|
return c;
|
|
|
|
}
|
2021-03-21 20:17:31 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected static final Config config = new Config();
|
|
|
|
|
|
|
|
public static Config getConfig() {
|
|
|
|
return config;
|
|
|
|
}
|
|
|
|
|
|
|
|
public static class Config {
|
|
|
|
public ChatColor decorationColor = ChatColor.YELLOW;
|
|
|
|
public char decorationChar = '-';
|
|
|
|
public int nbCharMargin = 1;
|
|
|
|
public ChatColor successColor = ChatColor.GREEN;
|
|
|
|
public ChatColor failureColor = ChatColor.RED;
|
|
|
|
public ChatColor infoColor = ChatColor.GOLD;
|
|
|
|
public ChatColor dataColor = ChatColor.GRAY;
|
|
|
|
public ChatColor urlColor = ChatColor.GREEN;
|
|
|
|
public ChatColor commandColor = ChatColor.GRAY;
|
|
|
|
public ChatColor highlightedCommandColor = ChatColor.WHITE;
|
|
|
|
public ChatColor broadcastColor = ChatColor.YELLOW;
|
|
|
|
public Supplier<Chat> prefix;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-11-02 23:23:41 +01:00
|
|
|
}
|