コード例 #1
0
  @Override
  public void load() {

    radius = ICUtil.parseRadius(getSign());
    if (getLine(2).contains("=")) {
      location = ICUtil.parseBlockLocation(getSign(), 2);
    } else {
      location = getBackBlock();
    }
  }
コード例 #2
0
  @Override
  public void load() {

    radius = ICUtil.parseRadius(getSign());
    String radiusString = radius.getBlockX() + "," + radius.getBlockY() + "," + radius.getBlockZ();
    if (radius.getBlockX() == radius.getBlockY() && radius.getBlockY() == radius.getBlockZ())
      radiusString = String.valueOf(radius.getBlockX());
    if (getLine(2).contains("=")) {
      getSign().setLine(2, radiusString + "=" + RegexUtil.EQUALS_PATTERN.split(getLine(2))[1]);
      centre = ICUtil.parseBlockLocation(getSign(), 2).getLocation();
    } else {
      getSign().setLine(2, radiusString);
      centre = getBackBlock().getLocation();
    }

    include = !getLine(3).startsWith("-");

    for (String bit : getLine(3).replace("-", "").split(",")) {

      filters.add(ItemUtil.getItem(bit));
    }

    chest = getBackBlock().getRelative(0, 1, 0);
  }