Create new branch. Goals: Make rocks size patches and frequency configruable. Optional but highly desired: Make rocks denser/more frequent the higher the altitude (make that an optional bool?)
Also the number display is screwed in the settings gui. Same problem as my other patch. Need to compare it to what I did for the other var I did recently (tiles width around rivers to make desert go away) and fix this. This will do to start with.
This commit is contained in:
@@ -365,7 +365,7 @@ void GenerateClearTile()
|
||||
|
||||
IncreaseGeneratingWorldProgress(GWP_ROUGH_ROCKY);
|
||||
if (IsTileType(tile, MP_CLEAR) && !IsClearGround(tile, CLEAR_DESERT)) {
|
||||
uint j = GB(r, 16, 4) + 5;
|
||||
uint j = GB(r, 16, 4) + _settings_game.game_creation.amount_of_rocks;
|
||||
for (;;) {
|
||||
TileIndex tile_new;
|
||||
|
||||
|
@@ -1459,6 +1459,8 @@ STR_CONFIG_SETTING_VARIETY :Variety distrib
|
||||
STR_CONFIG_SETTING_VARIETY_HELPTEXT :(TerraGenesis only) Control whether the map contains both mountainous and flat areas. Since this only makes the map flatter, other settings should be set to mountainous
|
||||
STR_CONFIG_SETTING_RIVER_AMOUNT :River amount: {STRING2}
|
||||
STR_CONFIG_SETTING_RIVER_AMOUNT_HELPTEXT :Choose how many rivers to generate
|
||||
STR_CONFIG_SETTING_ROCKS_AMOUNT :Rocks amount: {NUM}
|
||||
STR_CONFIG_SETTING_ROCKS_AMOUNT_HELPTEXT :Choose how many rocky patches to generate
|
||||
STR_CONFIG_SETTING_TREE_PLACER :Tree placer algorithm: {STRING2}
|
||||
STR_CONFIG_SETTING_TREE_PLACER_HELPTEXT :Choose the distribution of trees on the map: 'Original' plants trees uniformly scattered, 'Improved' plants them in groups
|
||||
STR_CONFIG_SETTING_TREE_PLACER_NONE :None
|
||||
|
@@ -1816,6 +1816,7 @@ static SettingsContainer &GetSettingsTree()
|
||||
genworld->Add(new SettingEntry("game_creation.snow_line_height"));
|
||||
genworld->Add(new SettingEntry("game_creation.rainforest_line_height"));
|
||||
genworld->Add(new SettingEntry("game_creation.amount_of_rivers"));
|
||||
genworld->Add(new SettingEntry("game_creation.amount_of_rocks"));
|
||||
genworld->Add(new SettingEntry("game_creation.tree_placer"));
|
||||
genworld->Add(new SettingEntry("vehicle.road_side"));
|
||||
genworld->Add(new SettingEntry("economy.larger_towns"));
|
||||
|
@@ -375,6 +375,7 @@ struct GameCreationSettings {
|
||||
byte min_river_length; ///< the minimum river length
|
||||
byte river_route_random; ///< the amount of randomicity for the route finding
|
||||
byte amount_of_rivers; ///< the amount of rivers
|
||||
byte amount_of_rocks; ///< the amoutn of rocks
|
||||
};
|
||||
|
||||
/** Settings related to construction in-game */
|
||||
|
@@ -3750,6 +3750,18 @@ str = STR_CONFIG_SETTING_RIVER_AMOUNT
|
||||
strhelp = STR_CONFIG_SETTING_RIVER_AMOUNT_HELPTEXT
|
||||
strval = STR_RIVERS_NONE
|
||||
|
||||
[SDT_VAR]
|
||||
base = GameSettings
|
||||
var = game_creation.amount_of_rocks
|
||||
type = SLE_UINT8
|
||||
def = 5
|
||||
min = 1
|
||||
max = 255
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_ROCKS_AMOUNT
|
||||
strhelp = STR_CONFIG_SETTING_ROCKS_AMOUNT_HELPTEXT
|
||||
strval = STR_JUST_COMMA
|
||||
|
||||
;;game_creation.build_public_roads
|
||||
[SDT_NULL]
|
||||
length = 1
|
||||
|
Reference in New Issue
Block a user