Clean up message sanitization and properly strip section signs from nicks/messages

This commit is contained in:
Allink
2022-05-25 17:15:04 +01:00
parent dfd90af017
commit 0fc5b01b29
4 changed files with 80 additions and 61 deletions

View File

@ -45,7 +45,7 @@ public class Command_vanish extends FreedomCommand
msg("You have unvanished.", ChatColor.GOLD);
FUtil.bcastMsg(plugin.rm.craftLoginMessage(playerSender, null));
FUtil.bcastMsg(playerSender.getName() + " joined the game.", ChatColor.YELLOW);
plugin.dc.messageChatChannel("**" + playerSender.getName() + " joined the server" + "**");
plugin.dc.messageChatChannel("**" + playerSender.getName() + " joined the server" + "**", true);
}
PlayerData playerData = plugin.pl.getData(playerSender);
@ -91,7 +91,7 @@ public class Command_vanish extends FreedomCommand
{
msg("You have vanished.", ChatColor.GOLD);
FUtil.bcastMsg(playerSender.getName() + " left the game.", ChatColor.YELLOW);
plugin.dc.messageChatChannel("**" + playerSender.getName() + " left the server" + "**");
plugin.dc.messageChatChannel("**" + playerSender.getName() + " left the server" + "**", true);
}
FLog.info(playerSender.getName() + " is now vanished.");