From 96c58e7b1c2f4ba9c6a825ce2b6e8b00dc87dc89 Mon Sep 17 00:00:00 2001 From: MrMicky Date: Tue, 8 Oct 2019 13:25:37 +0200 Subject: [PATCH] Fix scoreboard colors on 1.13 --- .../protocol1_13to1_12_2/Protocol1_13To1_12_2.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java index 3aac71e72..9039c7168 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java @@ -105,8 +105,7 @@ public class Protocol1_13To1_12_2 extends Protocol { }; // These are arbitrary rewrite values, it just needs an invalid color code character. - protected static EnumMap SCOREBOARD_TEAM_NAME_REWRITE = new EnumMap<>(ChatColor.class); - // @formatter:on + protected static final EnumMap SCOREBOARD_TEAM_NAME_REWRITE = new EnumMap<>(ChatColor.class); static { SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.BLACK, 'g'); @@ -125,6 +124,13 @@ public class Protocol1_13To1_12_2 extends Protocol { SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.LIGHT_PURPLE, 'z'); SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.YELLOW, '!'); SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.WHITE, '?'); + SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.MAGIC, '#'); + SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.BOLD, '('); + SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.STRIKETHROUGH, ')'); + SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.UNDERLINE, ':'); + SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.ITALIC, ';'); + SCOREBOARD_TEAM_NAME_REWRITE.put(ChatColor.RESET, '/'); + MappingData.init(); ConnectionData.init(); RecipeData.init();