mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-24 19:46:21 +01:00
Use ColouredConsoleSender to send chat to console. Thanks TheDgtl!
This commit is contained in:
parent
3c5ecd0854
commit
958acee5af
@ -7,6 +7,7 @@ import java.util.logging.Logger;
|
||||
|
||||
// CraftBukkit start
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.craftbukkit.command.ColouredConsoleSender;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.command.CommandException;
|
||||
import org.bukkit.craftbukkit.block.CraftBlock;
|
||||
@ -685,7 +686,8 @@ public class NetServerHandler extends NetHandler implements ICommandListener {
|
||||
}
|
||||
|
||||
s = String.format(event.getFormat(), event.getPlayer().getDisplayName(), event.getMessage());
|
||||
a.info(s);
|
||||
ColouredConsoleSender c = new ColouredConsoleSender(this.minecraftServer.server);
|
||||
c.sendMessage(s);
|
||||
for (Player recipient : event.getRecipients()) {
|
||||
recipient.sendMessage(s);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user