diff --git a/TheButtonAutoFlair.jar b/TheButtonAutoFlair.jar index 47c2da5..bee080c 100644 Binary files a/TheButtonAutoFlair.jar and b/TheButtonAutoFlair.jar differ diff --git a/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/Commands.java b/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/Commands.java index ddf741e..f4326ba 100644 --- a/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/Commands.java +++ b/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/Commands.java @@ -191,8 +191,9 @@ public class Commands implements CommandExecutor { p.RainbowPresserColorMode = false; p.OtherColorMode = Short.parseShort(args[1], 16); if (p.OtherColorMode != 0xFF) - player.sendMessage("§eMessage color set to §" - + p.OtherColorMode + p.OtherColorMode); + player.sendMessage(String.format( + "§eMessage color set to §%x%x", + p.OtherColorMode, p.OtherColorMode)); else player.sendMessage("§eMessage color reset."); } diff --git a/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/PlayerListener.java b/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/PlayerListener.java index 6f551ee..68e3a84 100644 --- a/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/PlayerListener.java +++ b/TheButtonAutoFlair/src/tk/sznp/thebuttonautoflair/PlayerListener.java @@ -10,6 +10,7 @@ import java.util.Random; import java.util.Timer; import java.util.TimerTask; import java.util.UUID; +import java.util.regex.Matcher; import java.util.regex.Pattern; import org.bukkit.Bukkit; @@ -255,8 +256,10 @@ public class PlayerListener implements Listener { // 2015.07.16. else rpc = 0; } - formattedmessage = formattedmessage.replace(item, "§" - + RainbowPresserColors[rpc] + item); + formattedmessage = formattedmessage.replaceFirst( + "(?i)" + Pattern.quote(item), + Matcher.quoteReplacement("§" + + RainbowPresserColors[rpc] + item)); if (rpc + 1 < RainbowPresserColors.length) rpc++; else diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands$2.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands$2.class index 2501abe..f952630 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands$2.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands$2.class differ diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands.class index c292ee5..489ae70 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/Commands.class differ diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$1.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$1.class index b64d940..aa9650a 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$1.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$1.class differ diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$2.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$2.class index 2ab6097..b18a27f 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$2.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$2.class differ diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$3.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$3.class index f13a8b6..577e9cc 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$3.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$3.class differ diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$4.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$4.class index f233306..b4fd590 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$4.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener$4.class differ diff --git a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener.class b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener.class index 4077048..a11798d 100644 Binary files a/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener.class and b/TheButtonAutoFlair/target/classes/tk/sznp/thebuttonautoflair/PlayerListener.class differ