Examples of ChatColor


Examples of org.bukkit.ChatColor

    }

    public void chat(String sourcePlayer, String message)
    {
        Server serv = Residence.getServ();
        ChatColor color = Residence.getConfigManager().getChatColor();
        ResidenceChatEvent cevent = new ResidenceChatEvent(Residence.getResidenceManager().getByName(name),serv.getPlayer(sourcePlayer),message,color);
        Residence.getServ().getPluginManager().callEvent(cevent);
        if(cevent.isCancelled())
            return;
        for(String member : members)
View Full Code Here

Examples of org.bukkit.ChatColor

                            break thisIC;

                    }
                }
                col = !col;
                ChatColor colour = col ? ChatColor.YELLOW : ChatColor.GOLD;

                if (!ICMechanic.checkPermissionsBoolean(CraftBookPlugin.inst().wrapPlayer(p), ric.getFactory(), ic.toLowerCase(Locale.ENGLISH))) {
                    colour = col ? ChatColor.RED : ChatColor.DARK_RED;
                }
                strings.add(colour + tic.getTitle() + " (" + ric.getId() + ")"
View Full Code Here

Examples of org.bukkit.ChatColor

  }

  @Override
  public ChatColor select(String arg, CommandSender sender)
  {
    ChatColor ret = null;
   
    arg = getToCompare(arg);
   
    for (ChatColor cc : ChatColor.values())
    {
View Full Code Here

Examples of org.bukkit.ChatColor

    private static JSONObject convert(String text) {
        // state
        final List<JSONObject> items = new LinkedList<>();
        final Set<ChatColor> formatting = EnumSet.noneOf(ChatColor.class);
        final StringBuilder current = new StringBuilder();
        ChatColor color = null;

        // work way through text, converting colors
        for (int i = 0; i < text.length(); ++i) {
            char ch = text.charAt(i);
            if (ch != ChatColor.COLOR_CHAR) {
                // no special handling
                current.append(ch);
                continue;
            }

            if (i == text.length() - 1) {
                // ignore color character at end
                continue;
            }

            // handle colors
            append(items, current, color, formatting);
            ChatColor code = ChatColor.getByChar(text.charAt(++i));
            if (code == ChatColor.RESET) {
                color = null;
                formatting.clear();
            } else if (code.isFormat()) {
                formatting.add(code);
            } else {
                color = code;
                formatting.clear();
            }
View Full Code Here

Examples of org.bukkit.ChatColor

    // Spawns a new NPC and registers it.
    public static void register(int UID, String owner, NPCCreateReason reason) {
        Location loc = PropertyManager.getBasic().getLocation(UID);

        ChatColor colour = PropertyManager.getBasic().getColour(UID);
        String name = PropertyManager.getBasic().getName(UID);
        name = ChatColor.stripColor(name);
        if (!Settings.getString("SpaceChar").isEmpty()) {
            name = name.replace(Settings.getString("SpaceChar"), " ");
        }
View Full Code Here

Examples of org.bukkit.ChatColor

    //TODO: info if there are no games at all

    // cycle through possible games
    for (Game game: getGames()) {
      // color and information on game
      ChatColor color;
      // name of arena
      String fullName = game.getName(); // name of arena
      String information;
      if (game.isEnabled() == false) {
        color = ChatColor.DARK_GRAY; // arena has been disabled in the the config
View Full Code Here

Examples of org.bukkit.ChatColor

    sender.sendMessage(SimpleSpleef.ll("feedback.infoHeader", "[ARENA]", ChatColor.DARK_AQUA + game.getId()));
    // full name of arena
    sender.sendMessage(SimpleSpleef.ll("feedback.infoName", "[NAME]", ChatColor.DARK_AQUA + game.getName()));
    // status of arena
    String information;
    ChatColor color;
    if (game.isActive()) { // game running
      if (game.isJoinable() || game.isReady()) {
        information = SimpleSpleef.ll("feedback.arenaJoinable");
        color = ChatColor.GREEN;
      } else {
View Full Code Here

Examples of org.bukkit.ChatColor

    // create list of spleefers
    String comma = SimpleSpleef.ll("feedback.infoComma");
    StringBuilder builder = new StringBuilder();
    for (int team = Spleefer.TEAM_RED; team >= Spleefer.TEAM_NONE; team--) {
      // color
      ChatColor teamColor;
      switch (team) {
      case Spleefer.TEAM_BLUE: teamColor = ChatColor.BLUE; break;
      case Spleefer.TEAM_RED: teamColor = ChatColor.RED; break;
      default: teamColor = ChatColor.WHITE;
      }
View Full Code Here

Examples of org.bukkit.ChatColor

        this.setItemsPerPage(8); // SUPPRESS CHECKSTYLE: MagicNumberCheck
    }

    private List<String> getFancyAnchorList(Player p) {
        List<String> anchorList = new ArrayList<String>();
        ChatColor color = ChatColor.GREEN;
        for (String anchor : this.plugin.getAnchorManager().getAnchors(p)) {
            anchorList.add(color + anchor);
            color = (color == ChatColor.GREEN) ? ChatColor.GOLD : ChatColor.GREEN;
        }
        return anchorList;
View Full Code Here

Examples of org.bukkit.ChatColor

    public boolean getBedRespawn() {
        return this.bedRespawn;
    }

    public String getAllPropertyNames() {
        ChatColor myColor = ChatColor.AQUA;
        StringBuilder result = new StringBuilder();
        Map<String, Object> serialized = this.serialize();
        for (String key : serialized.keySet()) {
            result.append(myColor).append(key).append(' ');
            myColor = (myColor == ChatColor.AQUA) ? ChatColor.GOLD : ChatColor.AQUA;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.