Пример #1
0
  public void info() {

    World world = null;

    if (this.args.length == 1 && this.sender instanceof Player) {
      world = ((Player) this.sender).getLocation().getWorld();
    } else if (this.args.length > 1) {
      world = Bukkit.getWorld(this.args[1]);

      if (world == null) {
        message("World <" + this.args[1] + "> does not exist");
        return;
      }
    } else return;

    Map map = this.editor.getMap(world);

    if (map == null) {
      message("World <" + world.getName() + "> is not oppened in editor");
      return;
    }

    // Informations sur la map
    message(ChatColor.DARK_AQUA + "Map <" + map.getWorldName() + ">");
    message("Object count : " + map.getSigns().size());
    message(
        "Available objects ("
            + ObjectType.getObjectTypeNames().size()
            + ") : "
            + ObjectType.getObjectTypeNames());
  }