summaryrefslogtreecommitdiff
path: root/src/tgp.cpp
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2021-03-24 16:38:36 +0100
committerPatric Stout <github@truebrain.nl>2021-03-26 12:22:32 +0100
commit70bc55cfd6e14f710427012b03aa211a0d85ca0f (patch)
treeb61c6c7e26f799afe542000d77f7cd3811d252d4 /src/tgp.cpp
parentcafe4eed6e482149eefe75393ad3a13e0f6e7ffe (diff)
downloadopenttd-70bc55cfd6e14f710427012b03aa211a0d85ca0f.tar.xz
Feature: setting to indicate desert coverage for tropic climate
This is an indication value; the game tries to get as close as it can, but due to the complex tropic rules, that is unlikely to be exact. In the end, it picks a height-level to base the desert/tropic line on. This is strictly seen not needed, as we can convert any tile to either. But it is the simplest way to get started with this without redoing all related functions.
Diffstat (limited to 'src/tgp.cpp')
-rw-r--r--src/tgp.cpp11
1 files changed, 0 insertions, 11 deletions
diff --git a/src/tgp.cpp b/src/tgp.cpp
index d47cdecac..fabc91e2a 100644
--- a/src/tgp.cpp
+++ b/src/tgp.cpp
@@ -236,17 +236,6 @@ static height_t TGPGetMaxHeight()
int map_size_bucket = std::min(MapLogX(), MapLogY()) - MIN_MAP_SIZE_BITS;
int max_height_from_table = max_height[_settings_game.difficulty.terrain_type][map_size_bucket];
-
- /* Tropic needs tropical forest to have all industries, so make sure we allow TGP to generate this high.
- * Tropic forest always starts at 1/4th of the max height. */
- if (_settings_game.game_creation.landscape == LT_TROPIC) {
- max_height_from_table += CeilDiv(_settings_game.construction.max_heightlevel, 4);
- /* Make flat a bit more flat by removing "very flat" from it, to somewhat compensate for the increase we just did. */
- if (_settings_game.difficulty.terrain_type > 0) {
- max_height_from_table -= max_height[_settings_game.difficulty.terrain_type - 1][map_size_bucket];
- }
- }
-
return I2H(std::min<uint>(max_height_from_table, _settings_game.construction.max_heightlevel));
}