Index: src/lang/english.txt =================================================================== --- src/lang/english.txt (revision 11811) +++ src/lang/english.txt (working copy) @@ -1180,6 +1180,9 @@ STR_CONFIG_PATCHES_TOWN_LAYOUT_2X2_GRID :2x2 grid STR_CONFIG_PATCHES_TOWN_LAYOUT_3X3_GRID :3x3 grid +STR_CONFIG_PATCHES_TREE_GROWTH :{LTBLUE}Disable Tree Growth (saved in map): {ORANGE}{STRING1} +STR_CONFIG_PATCHES_TREE_GROWTH_IN_EDITOR :{LTBLUE}Disable Tree Growth in Scenario Editor (not saved in map): {ORANGE}{STRING1} + STR_CONFIG_PATCHES_TOOLBAR_POS :{LTBLUE}Position of main toolbar: {ORANGE}{STRING1} STR_CONFIG_PATCHES_TOOLBAR_POS_LEFT :Left STR_CONFIG_PATCHES_TOOLBAR_POS_CENTER :Centre Index: src/saveload.cpp =================================================================== --- src/saveload.cpp (revision 11811) +++ src/saveload.cpp (working copy) @@ -34,7 +34,7 @@ #include "autoreplace_base.h" #include -extern const uint16 SAVEGAME_VERSION = 83; +extern const uint16 SAVEGAME_VERSION = 84; uint16 _sl_version; ///< the major savegame version identifier byte _sl_minor_version; ///< the minor savegame version, DO NOT USE! Index: src/settings.cpp =================================================================== --- src/settings.cpp (revision 11811) +++ src/settings.cpp (working copy) @@ -1382,6 +1382,8 @@ SDT_VAR(Patches, drag_signals_density,SLE_UINT8,S, 0, 4, 1, 20, 0, STR_CONFIG_PATCHES_DRAG_SIGNALS_DENSITY,NULL), SDT_VAR(Patches, semaphore_build_before,SLE_INT32, S, NC, 1975, MIN_YEAR, MAX_YEAR, 1, STR_CONFIG_PATCHES_SEMAPHORE_BUILD_BEFORE_DATE, NULL), SDT_CONDVAR(Patches, town_layout, SLE_UINT8, 59, SL_MAX_VERSION, 0, MS, TL_ORIGINAL, TL_NO_ROADS, NUM_TLS - 1, 1, STR_CONFIG_PATCHES_TOWN_LAYOUT, CheckTownLayout), + SDT_CONDBOOL(Patches, disable_tree_growth, 84, SL_MAX_VERSION, 0, 0, false, STR_CONFIG_PATCHES_TREE_GROWTH, NULL), + SDT_BOOL(Patches, disable_tree_growth_in_editor, S, 0, false, STR_CONFIG_PATCHES_TREE_GROWTH_IN_EDITOR, NULL), /***************************************************************************/ /* Vehicle section of the GUI-configure patches window */ Index: src/settings_gui.cpp =================================================================== --- src/settings_gui.cpp (revision 11811) +++ src/settings_gui.cpp (working copy) @@ -734,6 +734,8 @@ "drag_signals_density", "oil_refinery_limit", "semaphore_build_before", + "disable_tree_growth", + "disable_tree_growth_in_editor" }; static const char *_patches_stations[] = { Index: src/settings_type.h =================================================================== --- src/settings_type.h (revision 11811) +++ src/settings_type.h (working copy) @@ -85,6 +85,8 @@ uint8 advanced_vehicle_list; // Use the "advanced" vehicle list uint8 loading_indicators; // Show loading indicators uint8 default_rail_type; ///< The default rail type for the rail GUI + bool disable_tree_growth; ///< If trees are allowed to grow + bool disable_tree_growth_in_editor; ///< If trees are allowed to grow within the scenario editor uint8 toolbar_pos; // position of toolbars, 0=left, 1=center, 2=right uint8 window_snap_radius; // Windows snap at each other if closer than this Index: src/tree_cmd.cpp =================================================================== --- src/tree_cmd.cpp (revision 11811) +++ src/tree_cmd.cpp (working copy) @@ -599,6 +599,10 @@ } SetTreeCounter(tile, 0); + /* Exit here if trees are not allowed to grow */ + if (_patches.disable_tree_growth) return; + if ((_game_mode == GM_EDITOR) && (_patches.disable_tree_growth_in_editor)) return; + switch (GetTreeGrowth(tile)) { case 3: /* regular sized tree */ if (_opt.landscape == LT_TROPIC && @@ -673,6 +677,10 @@ void OnTick_Trees() { + /* Exit here if trees are not allowed to grow */ + if (_patches.disable_tree_growth) return; + if ((_game_mode == GM_EDITOR) && (_patches.disable_tree_growth_in_editor)) return; + uint32 r; TileIndex tile; ClearGround ct;