feat: add support for hex colour codes on spigot

* Update Lang.java

https://www.spigotmc.org/threads/chatcolor-implementation-%C2%A7x-x.505831/

* Update Lang Files

* Add version requirement
This commit is contained in:
TreemanKing 2024-05-12 12:13:27 +10:00 committed by Sekwah
parent 6386a89913
commit 94522c237f
5 changed files with 5 additions and 1 deletions

View File

@ -43,7 +43,7 @@ public class Lang {
if (instance.languageMap.containsKey(s)) {
String translation = instance.languageMap.get(s);
// noinspection ALL (not sure what the specific warning is for escaped unicode)
translation = translation.replaceAll("&([0-9a-frk-o])", "\u00A7$1");
translation = translation.replaceAll("&([0-9a-frk-ox])", "\u00A7$1");
return translation;
} else {
return s;

View File

@ -29,6 +29,7 @@
# &n Underline
# &o Italic
# &r Reset
# &x Hex Color (#aa5f10 represented by &x&a&a&5&f&1&0) - Spigot 1.16.1+
#
# Also note that some debug messages may not be listed here for translation.
#

View File

@ -29,6 +29,7 @@
# &n Underline
# &o Italic
# &r Reset
# &x Hex Color (#aa5f10 represented by &x&a&a&5&f&1&0) - Spigot 1.16.1+
#
# Some debug messages may not be listed here for translation.

View File

@ -29,6 +29,7 @@
# &n Underline
# &o Italic
# &r Reset
# &x Hex Color (#aa5f10 represented by &x&a&a&5&f&1&0) - Spigot 1.16.1+
#
# Some debug messages may not be listed here for translation.

View File

@ -29,6 +29,7 @@
# &n Underline
# &o Italic
# &r Reset
# &x Hex Color (#aa5f10 represented by &x&a&a&5&f&1&0) - Spigot 1.16.1+
#
# Vegye figyelembe, hogy néhány hibaelhárító üzenet itt nem szerepel a fordításban.
#