src/station_cmd.cpp
changeset 9358 2e1e4d2f71dd
parent 9354 845e07db4549
child 9360 51762cddd6f2
equal deleted inserted replaced
9357:f540f1fb6bd9 9358:2e1e4d2f71dd
   294 	/* Check woods */
   294 	/* Check woods */
   295 	if (HasBit(free_names, M(STR_SV_STNAME_WOODS)) && (
   295 	if (HasBit(free_names, M(STR_SV_STNAME_WOODS)) && (
   296 				CountMapSquareAround(tile, CMSATree) >= 8 ||
   296 				CountMapSquareAround(tile, CMSATree) >= 8 ||
   297 				CountMapSquareAround(tile, CMSAForest) >= 2)
   297 				CountMapSquareAround(tile, CMSAForest) >= 2)
   298 			) {
   298 			) {
   299 		return _opt.landscape == LT_TROPIC ? STR_SV_STNAME_FOREST : STR_SV_STNAME_WOODS;
   299 		return _settings.game_creation.landscape == LT_TROPIC ? STR_SV_STNAME_FOREST : STR_SV_STNAME_WOODS;
   300 	}
   300 	}
   301 
   301 
   302 	/* check elevation compared to town */
   302 	/* check elevation compared to town */
   303 	uint z = GetTileZ(tile);
   303 	uint z = GetTileZ(tile);
   304 	uint z2 = GetTileZ(t->xy);
   304 	uint z2 = GetTileZ(t->xy);
  1679 
  1679 
  1680 	/* The steps for measuring noise reduction are based on the "magical" (and arbitrary) 8 base distance
  1680 	/* The steps for measuring noise reduction are based on the "magical" (and arbitrary) 8 base distance
  1681 	 * adding the town_council_tolerance 4 times, as a way to graduate, depending of the tolerance.
  1681 	 * adding the town_council_tolerance 4 times, as a way to graduate, depending of the tolerance.
  1682 	 * Basically, it says that the less tolerant a town is, the bigger the distance before
  1682 	 * Basically, it says that the less tolerant a town is, the bigger the distance before
  1683 	 * an actual decrease can be granted */
  1683 	 * an actual decrease can be granted */
  1684 	uint8 town_tolerance_distance = 8 + (_opt.diff.town_council_tolerance * 4);
  1684 	uint8 town_tolerance_distance = 8 + (_settings.difficulty.town_council_tolerance * 4);
  1685 
  1685 
  1686 	/* The airport is in the "inner" distance where there is no noise reduction */
  1686 	/* The airport is in the "inner" distance where there is no noise reduction */
  1687 	if (distance < town_tolerance_distance) return afc->noise_level;
  1687 	if (distance < town_tolerance_distance) return afc->noise_level;
  1688 
  1688 
  1689 	/* now, we want to have the distance segmented using the distance judged bareable by town
  1689 	/* now, we want to have the distance segmented using the distance judged bareable by town