Removed redondant aliases in ChatConfig.PandaTheme
This commit is contained in:
parent
2d7e7ba9b7
commit
29c1aa21c9
@ -13,63 +13,64 @@ public class ChatConfig {
|
|||||||
/**
|
/**
|
||||||
* The color used for decoration.
|
* The color used for decoration.
|
||||||
*/
|
*/
|
||||||
public static TextColor decorationColor = PandaTheme.CHAT_DECORATION_COLOR;
|
public static TextColor decorationColor = PandaTheme.CHAT_GREEN_1_NORMAL;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The character used as a pattern for decoration.
|
* The character used as a pattern for decoration.
|
||||||
*/
|
*/
|
||||||
public static char decorationChar = PandaTheme.CHAT_DECORATION_CHAR;
|
public static char decorationChar = '-';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The default margin for left and right aligned text.
|
* The number of decoration character to put between the text and the border of
|
||||||
|
* the line for left and right aligned text.
|
||||||
*/
|
*/
|
||||||
public static int nbCharMargin = PandaTheme.CHAT_NB_CHAR_MARGIN;
|
public static int nbCharMargin = 1;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used for successful messages.
|
* The color used for successful messages.
|
||||||
*/
|
*/
|
||||||
public static TextColor successColor = PandaTheme.CHAT_SUCCESS_COLOR;
|
public static TextColor successColor = PandaTheme.CHAT_GREEN_SATMAX;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used for error/failure messages.
|
* The color used for error/failure messages.
|
||||||
*/
|
*/
|
||||||
public static TextColor failureColor = PandaTheme.CHAT_FAILURE_COLOR;
|
public static TextColor failureColor = PandaTheme.CHAT_RED_FAILURE;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* the color used for informational messages.
|
* the color used for informational messages.
|
||||||
*/
|
*/
|
||||||
public static TextColor infoColor = PandaTheme.CHAT_INFO_COLOR;
|
public static TextColor infoColor = PandaTheme.CHAT_GREEN_4;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used for warning messages.
|
* The color used for warning messages.
|
||||||
*/
|
*/
|
||||||
public static TextColor warningColor = PandaTheme.CHAT_WARNING_COLOR;
|
public static TextColor warningColor = PandaTheme.CHAT_BROWN_2_SAT;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used to display data in a message.
|
* The color used to display data in a message.
|
||||||
*/
|
*/
|
||||||
public static TextColor dataColor = PandaTheme.CHAT_DATA_COLOR;
|
public static TextColor dataColor = PandaTheme.CHAT_GRAY_MID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used for displayed URLs and clickable URLs.
|
* The color used for displayed URLs and clickable URLs.
|
||||||
*/
|
*/
|
||||||
public static TextColor urlColor = PandaTheme.CHAT_URL_COLOR;
|
public static TextColor urlColor = PandaTheme.CHAT_GREEN_1_NORMAL;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used for displayed commands and clickable commands.
|
* The color used for displayed commands and clickable commands.
|
||||||
*/
|
*/
|
||||||
public static TextColor commandColor = PandaTheme.CHAT_COMMAND_COLOR;
|
public static TextColor commandColor = PandaTheme.CHAT_GRAY_MID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color sued to display a command that is highlighted. For example, the current page in a pagination.
|
* The color sued to display a command that is highlighted. For example, the current page in a pagination.
|
||||||
*/
|
*/
|
||||||
public static TextColor highlightedCommandColor = PandaTheme.CHAT_COMMAND_HIGHLIGHTED_COLOR;
|
public static TextColor highlightedCommandColor = NamedTextColor.WHITE;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The color used for broadcasted messages.
|
* The color used for broadcasted messages.
|
||||||
* It is often used in combination with {@link #prefix}.
|
* It is often used in combination with {@link #prefix}.
|
||||||
*/
|
*/
|
||||||
public static TextColor broadcastColor = PandaTheme.CHAT_BROADCAST_COLOR;
|
public static TextColor broadcastColor = NamedTextColor.YELLOW;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The prefix used for prefixed messages.
|
* The prefix used for prefixed messages.
|
||||||
@ -116,19 +117,7 @@ public class ChatConfig {
|
|||||||
|
|
||||||
public static final TextColor CHAT_GRAY_MID = TextColor.fromHexString("#888888");
|
public static final TextColor CHAT_GRAY_MID = TextColor.fromHexString("#888888");
|
||||||
|
|
||||||
public static final TextColor CHAT_BROADCAST_COLOR = NamedTextColor.YELLOW;
|
public static final TextColor CHAT_RED_FAILURE = TextColor.fromHexString("#ff3333");
|
||||||
|
|
||||||
|
|
||||||
public static final TextColor CHAT_DECORATION_COLOR = CHAT_GREEN_1_NORMAL;
|
|
||||||
public static final char CHAT_DECORATION_CHAR = '-';
|
|
||||||
public static final TextColor CHAT_URL_COLOR = CHAT_GREEN_1_NORMAL;
|
|
||||||
public static final TextColor CHAT_COMMAND_COLOR = CHAT_GRAY_MID;
|
|
||||||
public static final TextColor CHAT_COMMAND_HIGHLIGHTED_COLOR = NamedTextColor.WHITE;
|
|
||||||
public static final TextColor CHAT_INFO_COLOR = CHAT_GREEN_4;
|
|
||||||
public static final TextColor CHAT_WARNING_COLOR = CHAT_BROWN_2_SAT;
|
|
||||||
public static final TextColor CHAT_SUCCESS_COLOR = CHAT_GREEN_SATMAX;
|
|
||||||
public static final TextColor CHAT_FAILURE_COLOR = TextColor.fromHexString("#ff3333");
|
|
||||||
public static final TextColor CHAT_DATA_COLOR = CHAT_GRAY_MID;
|
|
||||||
|
|
||||||
|
|
||||||
public static final TextColor CHAT_PM_PREFIX_DECORATION = CHAT_BROWN_2_SAT;
|
public static final TextColor CHAT_PM_PREFIX_DECORATION = CHAT_BROWN_2_SAT;
|
||||||
@ -138,12 +127,6 @@ public class ChatConfig {
|
|||||||
|
|
||||||
public static final TextColor CHAT_DISCORD_LINK_COLOR = TextColor.fromHexString("#00aff4");
|
public static final TextColor CHAT_DISCORD_LINK_COLOR = TextColor.fromHexString("#00aff4");
|
||||||
|
|
||||||
/**
|
|
||||||
* Number of decoration character to put between the text and the border of
|
|
||||||
* the line for left and right aligned text.
|
|
||||||
*/
|
|
||||||
public static final int CHAT_NB_CHAR_MARGIN = 1;
|
|
||||||
|
|
||||||
|
|
||||||
public static Chat CHAT_MESSAGE_PREFIX() {
|
public static Chat CHAT_MESSAGE_PREFIX() {
|
||||||
return Chat.text("[")
|
return Chat.text("[")
|
||||||
|
@ -92,7 +92,7 @@ public class PerformanceAnalysisManager implements Listener {
|
|||||||
.add(5, NamedTextColor.RED)
|
.add(5, NamedTextColor.RED)
|
||||||
.add(10, NamedTextColor.GOLD)
|
.add(10, NamedTextColor.GOLD)
|
||||||
.add(14, NamedTextColor.YELLOW)
|
.add(14, NamedTextColor.YELLOW)
|
||||||
.add(20, PandaTheme.CHAT_DECORATION_COLOR)
|
.add(20, PandaTheme.CHAT_GREEN_1_NORMAL)
|
||||||
.add(26, NamedTextColor.BLUE);
|
.add(26, NamedTextColor.BLUE);
|
||||||
|
|
||||||
|
|
||||||
@ -101,7 +101,7 @@ public class PerformanceAnalysisManager implements Listener {
|
|||||||
.add(5, NamedTextColor.RED)
|
.add(5, NamedTextColor.RED)
|
||||||
.add(10, NamedTextColor.GOLD)
|
.add(10, NamedTextColor.GOLD)
|
||||||
.add(14, NamedTextColor.YELLOW)
|
.add(14, NamedTextColor.YELLOW)
|
||||||
.add(18, PandaTheme.CHAT_DECORATION_COLOR);
|
.add(18, PandaTheme.CHAT_GREEN_1_NORMAL);
|
||||||
|
|
||||||
|
|
||||||
public final ChatColorGradient tps1mGradient = new ChatColorGradient()
|
public final ChatColorGradient tps1mGradient = new ChatColorGradient()
|
||||||
@ -109,10 +109,10 @@ public class PerformanceAnalysisManager implements Listener {
|
|||||||
.add(8, NamedTextColor.RED)
|
.add(8, NamedTextColor.RED)
|
||||||
.add(12, NamedTextColor.GOLD)
|
.add(12, NamedTextColor.GOLD)
|
||||||
.add(16, NamedTextColor.YELLOW)
|
.add(16, NamedTextColor.YELLOW)
|
||||||
.add(20, PandaTheme.CHAT_DECORATION_COLOR);
|
.add(20, PandaTheme.CHAT_GREEN_1_NORMAL);
|
||||||
|
|
||||||
public final ChatColorGradient memoryUsageGradient = new ChatColorGradient()
|
public final ChatColorGradient memoryUsageGradient = new ChatColorGradient()
|
||||||
.add(.60f, PandaTheme.CHAT_DECORATION_COLOR)
|
.add(.60f, PandaTheme.CHAT_GREEN_1_NORMAL)
|
||||||
.add(.70f, NamedTextColor.YELLOW)
|
.add(.70f, NamedTextColor.YELLOW)
|
||||||
.add(.80f, NamedTextColor.GOLD)
|
.add(.80f, NamedTextColor.GOLD)
|
||||||
.add(.90f, NamedTextColor.RED)
|
.add(.90f, NamedTextColor.RED)
|
||||||
@ -326,14 +326,14 @@ public class PerformanceAnalysisManager implements Listener {
|
|||||||
float avgTickDuration1s = getAvgNano(tpsDurations, nbTick1s)/1_000_000;
|
float avgTickDuration1s = getAvgNano(tpsDurations, nbTick1s)/1_000_000;
|
||||||
|
|
||||||
float avgTickCPUTime1s = getAvgNano(tpsCPUTimes, nbTick1s)/1_000_000;
|
float avgTickCPUTime1s = getAvgNano(tpsCPUTimes, nbTick1s)/1_000_000;
|
||||||
TextColor avgTickCPUTime1sColor = (avgTickDuration1s < 46 || avgTickCPUTime1s < 20) ? PandaTheme.CHAT_DECORATION_COLOR
|
TextColor avgTickCPUTime1sColor = (avgTickDuration1s < 46 || avgTickCPUTime1s < 20) ? PandaTheme.CHAT_GREEN_1_NORMAL
|
||||||
: (avgTickCPUTime1s < 30) ? NamedTextColor.YELLOW
|
: (avgTickCPUTime1s < 30) ? NamedTextColor.YELLOW
|
||||||
: (avgTickCPUTime1s < 40) ? NamedTextColor.GOLD
|
: (avgTickCPUTime1s < 40) ? NamedTextColor.GOLD
|
||||||
: (avgTickCPUTime1s < 50) ? NamedTextColor.RED
|
: (avgTickCPUTime1s < 50) ? NamedTextColor.RED
|
||||||
: NamedTextColor.DARK_RED;
|
: NamedTextColor.DARK_RED;
|
||||||
|
|
||||||
float avgTickWaitingTime1s = avgTickDuration1s - avgTickCPUTime1s;
|
float avgTickWaitingTime1s = avgTickDuration1s - avgTickCPUTime1s;
|
||||||
TextColor avgTickWaitingTime1sColor = (avgTickDuration1s < 46 || avgTickWaitingTime1s < 20) ? PandaTheme.CHAT_DECORATION_COLOR
|
TextColor avgTickWaitingTime1sColor = (avgTickDuration1s < 46 || avgTickWaitingTime1s < 20) ? PandaTheme.CHAT_GREEN_1_NORMAL
|
||||||
: (avgTickWaitingTime1s < 30) ? NamedTextColor.YELLOW
|
: (avgTickWaitingTime1s < 30) ? NamedTextColor.YELLOW
|
||||||
: (avgTickWaitingTime1s < 40) ? NamedTextColor.GOLD
|
: (avgTickWaitingTime1s < 40) ? NamedTextColor.GOLD
|
||||||
: (avgTickWaitingTime1s < 50) ? NamedTextColor.RED
|
: (avgTickWaitingTime1s < 50) ? NamedTextColor.RED
|
||||||
@ -342,7 +342,7 @@ public class PerformanceAnalysisManager implements Listener {
|
|||||||
|
|
||||||
|
|
||||||
float avgInterTickDuration1s = getAvgNano(interTPSDurations, nbTick1s)/1_000_000;
|
float avgInterTickDuration1s = getAvgNano(interTPSDurations, nbTick1s)/1_000_000;
|
||||||
TextColor avgInterTickDuration1sColor = (avgInterTickDuration1s > 10) ? PandaTheme.CHAT_DECORATION_COLOR
|
TextColor avgInterTickDuration1sColor = (avgInterTickDuration1s > 10) ? PandaTheme.CHAT_GREEN_1_NORMAL
|
||||||
: (avgInterTickDuration1s > 4) ? NamedTextColor.YELLOW
|
: (avgInterTickDuration1s > 4) ? NamedTextColor.YELLOW
|
||||||
: (avgTickDuration1s < 46) ? NamedTextColor.GOLD
|
: (avgTickDuration1s < 46) ? NamedTextColor.GOLD
|
||||||
: NamedTextColor.RED;
|
: NamedTextColor.RED;
|
||||||
|
Loading…
Reference in New Issue
Block a user