Example #1
0
  public static void adminChatMessage(
      CommandSender sender, String message, boolean senderIsConsole) {
    String name =
        sender.getName() + " " + TFM_PlayerRank.fromSender(sender).getPrefix() + ChatColor.WHITE;
    TFM_Log.info("[ADMIN] " + name + ": " + message);

    for (Player player : Bukkit.getOnlinePlayers()) {
      if (TFM_AdminList.isSuperAdmin(player)) {
        player.sendMessage(
            "["
                + ChatColor.AQUA
                + "ADMIN"
                + ChatColor.WHITE
                + "] "
                + ChatColor.DARK_RED
                + name
                + ": "
                + ChatColor.AQUA
                + message);
      }
    }
  }