anchor.diff:  
       if not FMap.IsOnMap(Level, cx,cy) then
       begin
  -      cur_tinfo := info;
  +			widthTooHigh := currentPos.x >= FMap.MapLevels[Level].Width;
  +			widthTooLess := currentPos.x < 0;
  +			heightTooHigh := currentPos.y >= FMap.MapLevels[Level].Height;
  +			heightTooLess := currentPos.y < 0;
  +
  + 			if ((widthTooHigh and heightTooHigh)
  +         or (widthTooHigh and heightTooLess)
  +         or (widthTooLess and heightTooHigh)
  +         or (widthTooLess and heightTooLess)) then
  +
  + 				cur_tinfo := info
  + 			else if widthTooHigh then
  +        cur_tinfo := GetTileInfo(currentPos.x - 1, currentPos.y)
  + 			else if heightTooHigh then
  +        cur_tinfo := GetTileInfo(currentPos.x, currentPos.y-1)
  + 			else if widthTooLess then
  + 				cur_tinfo := GetTileInfo(currentPos.x+1, currentPos.y)
  + 			else if heightTooLess then
  +        cur_tinfo := GetTileInfo(currentPos.x, currentPos.y-1)
  +      else
  +        cur_tinfo := info;
       end
       else
       begin
  
positive.code:      if Assigned(it)  then
       begin
         repeat
            UpdateTerrain(it.data, true);
         until not it.Next;
       end;
  
       FreeAndNil(it);
  
       it:=tiles.NativeTiles.Find(centerTile);
  
       if Assigned(it) then
  
negative.code: 
         invalidForeignTilesCnt:=MaxInt;
         invalidNativeTilesCnt:=0;
         centerPosValid := false;
  
          for i := 0 to rect.FWidth - 1 do
          begin
  