Open fabianmakila opened 1 year ago
Hello! I have looked into implementing this feature, but was quickly stopped by an idea.
punishment-expired-display
falls under the formatting
category, and is responsible for the %HAS_EXPIRED%
variable. But, variables are usually used in messages, which allow for color codes to be used. So, using the %HAS_EXPIRED%
variable with colors can be accomplished by coloring it like any other message.
But, at the same time I understand that this is not an ideal solution, in terms of the work required to set up messages, since you need to use color codes every time you want to use the variable. Allowing variables under the formatting
section to be colored allows for easier messages setup, but it does bring some challenges.
Most sections under the formatting
section in the configuration are implemented as String
s as opposed to Component
s, or TextComponent
s. They get their values set in Formatter.java#181, and well formatted in messages with punishments down the line. Making them colorable, to my understanding would require a small refactor in the formatting code.
I have confirmed that ...
Description
Some servers might want to color code the
Expired
andNot expired
texts seen in the/history
command to make it easier to differentiate between the two by a quick glance.My first intuition was to do this which doesn't work currently.
I'm proposing the addition of color code support for the two fields above, which would allow the use of colors without adding any additional fields to the configuration.