anchor.diff:        if count = NewPoint then
           break;
       end;
  -    Result[LocNum].X := Min(X << 4 + fRNG.RandomI(16), gTerrain.MapX-1);
  -    Result[LocNum].Y := Min(Y << 4 + fRNG.RandomI(16), gTerrain.MapY-1);
  +    Result[LocNum].X := Min(X << 4 + fRNG.RandomI(16), fMapX-1);
  +    Result[LocNum].Y := Min(Y << 4 + fRNG.RandomI(16), fMapY-1);
       FillDist(X, Y, 0, Dist);
     end;
   end;
  
positive.code:   i := 1;
    idxY := 0;
    Y := 1;
    while Y < gTerrain.MapY do
    begin
      idxX := 0;
      X := 1;
      while X < gTerrain.MapX do
      begin
        Points[idxY,idxX].Y := Min(gTerrain.MapY-1, Y + fRNG.RandomI(Step));
        Points[idxY,idxX].X := Min(gTerrain.MapX-1, X + fRNG.RandomI(Step));
        Y1 := Points[idxY,idxX].Y;
        X1 := Points[idxY,idxX].X;
        move := 0;
  
negative.code: //  end;
  //  //}
  //
  //	for Y1 := 1 to fMapY-1 do
  //  begin
  //    Y0 := Y1 - 1;
  //    Y2 := Y1 + 1;
  //    for X1 := 1 to fMapX-1 do
  //    begin
  //      {
  //      X0 := X1 - 1;
  