anchor.diff:  
   
   function TKMTerrain.TileHasParameter(X,Y: Word; aCheckTileFunc: TBooleanWordFunc; aAllow2CornerTiles: Boolean = True): Boolean;
  -var
  -  K, Cnt: Integer;
  -  Corners: TKMWordArray;
  +const
  +  PROHIBIT_TERKINDS: array[0..1] of TKMTerrainKind = (tkLava, tkAbyss);
  +var
  +  I, K, Cnt: Integer;
  +  Corners: TKMTerrainKindsArray;
   begin
     Result := False;
   
  
positive.code: 
  //Get tile corners terrain id
  function TKMTerrain.TileCornersTerrains(aX, aY: Word): TKMWordArray;
  const
    TOO_BIG_VALUE = 10000;
  var
    K, L: Integer;
  begin
    SetLength(Result, 4);
    for K := 0 to 3 do
    begin
      Result[K] := TOO_BIG_VALUE;
      with gTerrain.Land[aY,aX] do
      begin
        if K in BaseLayer.Corners then
          Result[K] := BASE_TERRAIN[TILE_CORNERS_TERRAIN_KINDS[BaseLayer.Terrain, (K + 4 - BaseLayer.Rotation) mod 4]]
        else
          for L := 0 to LayersCnt - 1 do
            if K in Layer[L].Corners then
            begin
              Result[K] := BASE_TERRAIN[gRes.Sprites.GetGenTerrainInfo(Layer[L].Terrain).TerKind];
              Break;
            end;
      end;
      Assert(Result[K] <> TOO_BIG_VALUE, Format('[TileCornerTerrains] Can''t determine tile [%d:%d] terrain at Corner [%d]', [aX, aY, K]));
    end;
  end;
  
  
  
negative.code: function TKMTerrain.TileGoodForGoldMine(X,Y: Word): Boolean;
  var
    CornersTKinds: TKMTerrainKindsArray;
  begin
    Result :=
      (fTileset.TileIsGoodForGoldMine(Land[Y,X].BaseLayer.Terrain)
        and (Land[Y,X].BaseLayer.Rotation mod 4 = 0)); //only horizontal mountain edges allowed
    if not Result then
    begin
      CornersTKinds := TileCornersTerKinds(X, Y);
      Result :=
            (CornersTKinds[0] in [tkGold, tkGoldMount])
        and (CornersTKinds[1] in [tkGold, tkGoldMount])
        and fTileset.TileIsRoadable(BASE_TERRAIN[CornersTKinds[2]])
        and fTileset.TileIsRoadable(BASE_TERRAIN[CornersTKinds[3]]);
    end;
  end;
  
  