@Override
  public boolean checkAndFormMultiblockStructure() {
    // Find the corner stone
    int xNegExtent = Integer.MAX_VALUE;
    int zNegExtent = Integer.MAX_VALUE;

    for (int x = 0; x < MAX_BORDER_SIZE; x++) {
      for (int z = 0; z < MAX_BORDER_SIZE; z++) {
        Block block = worldObj.getBlock(xCoord - x, yCoord, zCoord - z);
        if (block == Init.blockUncertaintyBorder) {
          xNegExtent = xCoord - x;
          zNegExtent = zCoord - z;
        }
      }
    }

    // Run the check
    TileEntityUncertaintyBorder cornerstone =
        (TileEntityUncertaintyBorder) worldObj.getTileEntity(xNegExtent, yCoord, zNegExtent);
    if (cornerstone == null) {
      // LogHelper.info("Could not find cornerstone");
      return false;
    }

    return cornerstone.checkMultiblockFromCornerstone();
  }
  @Override
  protected void formMultiblockStructure() {
    // Set the cornerstone as master
    setAsMaster();

    // Set other blocks
    for (int i = 0; i < xLength; i++) {
      TileEntityUncertaintyBorder tileEnt =
          (TileEntityUncertaintyBorder) worldObj.getTileEntity(xCoord + i, yCoord, zCoord);
      tileEnt.setAsSlave(xCoord, yCoord, zCoord, xLength, zLength);
      worldObj.setBlockMetadataWithNotify(xCoord + i, yCoord, zCoord, 1, 3);

      tileEnt =
          (TileEntityUncertaintyBorder)
              worldObj.getTileEntity(xCoord + i, yCoord, zCoord + zLength - 1);
      tileEnt.setAsSlave(xCoord, yCoord, zCoord, xLength, zLength);
      worldObj.setBlockMetadataWithNotify(xCoord + i, yCoord, zCoord + zLength - 1, 1, 3);
    }

    for (int i = 0; i < zLength; i++) {
      TileEntityUncertaintyBorder tileEnt =
          (TileEntityUncertaintyBorder) worldObj.getTileEntity(xCoord, yCoord, zCoord + i);
      tileEnt.setAsSlave(xCoord, yCoord, zCoord, xLength, zLength);
      worldObj.setBlockMetadataWithNotify(xCoord, yCoord, zCoord + i, 1, 3);

      tileEnt =
          (TileEntityUncertaintyBorder)
              worldObj.getTileEntity(xCoord + xLength - 1, yCoord, zCoord + i);
      tileEnt.setAsSlave(xCoord, yCoord, zCoord, xLength, zLength);
      worldObj.setBlockMetadataWithNotify(xCoord + xLength - 1, yCoord, zCoord + i, 1, 3);
    }
  }
  private void destroyMultiblock() {
    for (int i = 0; i < xLength; i++) {
      TileEntityUncertaintyBorder tileEnt =
          (TileEntityUncertaintyBorder) worldObj.getTileEntity(masterX + i, masterY, masterZ);
      if (tileEnt != null && (tileEnt.isMaster || tileEnt.isSlave())) {
        tileEnt.clearMultiblock();
        worldObj.setBlockMetadataWithNotify(masterX + i, masterY, masterZ, 0, 3);
      }

      tileEnt = null;
      tileEnt =
          (TileEntityUncertaintyBorder)
              worldObj.getTileEntity(masterX + i, masterY, masterZ + zLength - 1);
      if (tileEnt != null && (tileEnt.isMaster || tileEnt.isSlave())) {
        tileEnt.clearMultiblock();
        worldObj.setBlockMetadataWithNotify(masterX + i, masterY, masterZ + zLength - 1, 0, 3);
      }
    }

    for (int i = 0; i < zLength; i++) {
      TileEntityUncertaintyBorder tileEnt =
          (TileEntityUncertaintyBorder) worldObj.getTileEntity(masterX, masterY, masterZ + i);
      if (tileEnt != null && (tileEnt.isMaster || tileEnt.isSlave())) {
        tileEnt.clearMultiblock();
        worldObj.setBlockMetadataWithNotify(masterX, masterY, masterZ + i, 0, 3);
      }

      tileEnt = null;
      tileEnt =
          (TileEntityUncertaintyBorder)
              worldObj.getTileEntity(masterX + xLength - 1, masterY, masterZ + i);
      if (tileEnt != null && (tileEnt.isMaster || tileEnt.isSlave())) {
        tileEnt.clearMultiblock();
        worldObj.setBlockMetadataWithNotify(masterX + xLength - 1, masterY, masterZ + i, 0, 3);
      }
    }
  }