Update commands to match 1.3 vanilla commands

This commit is contained in:
feildmaster
2012-08-06 04:45:18 -05:00
parent c809871558
commit 09ef15e950
17 changed files with 39 additions and 20 deletions

View File

@@ -292,11 +292,15 @@ public abstract class Command {
}
public static void broadcastCommandMessage(CommandSender source, String message) {
broadcastCommandMessage(source, message, true);
}
public static void broadcastCommandMessage(CommandSender source, String message, boolean sendToSource) {
Set<Permissible> users = Bukkit.getPluginManager().getPermissionSubscriptions(Server.BROADCAST_CHANNEL_ADMINISTRATIVE);
String result = source.getName() + ": " + message;
String colored = ChatColor.GRAY + "(" + result + ")";
String colored = ChatColor.GRAY + "" + ChatColor.ITALIC + "[" + result + "]";
if (!(source instanceof ConsoleCommandSender)) {
if (sendToSource && !(source instanceof ConsoleCommandSender)) {
source.sendMessage(message);
}