Where are you better trees?

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

Post Reply
shaldoryn
Engineer
Engineer
Posts: 2
Joined: 14 Apr 2021 01:23

Where are you better trees?

Post by shaldoryn »

Hi guys,

I'm more or less a newbie and have a, probably, very stupid question..
I see on many screenshots nicer trees than the original ones.. but, no matter all the NewGRF's I've explored, or the searches I did, I can't figure out where those come from.
Could you please help? :p
I'm well speaking about the landscape generated trees, not objects of tree that you place as decor tile.
I'm very interested in the pin trees actually.
Thank you!
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Where are you better trees?

Post by kamnet »

OpenGFX+ Landscape provides improved versions of the default game's trees.

Many people like SAC's "Stolen Trees", but she released the much more improved, much better "INFRA Trees" some years later. You'll need to download these from Simuscape and unpack the .rar files into your "newgrf" folder (you can put them in a sub folder or re-pack them into a .tar file) Grab all three files. http://www.simuscape.net/simutalk/viewtopic.php?t=758

CZTR Tree Set is a still-developing NewGRF that has gotten a lot of attention over the last year due to its very detailed 32bpp and full-zoom graphics. They particularly stand out and look good even with OpenGFX or zBase ground sprites (but the CZTR Ground Set may be the best option for now).
ebla71
Transport Coordinator
Transport Coordinator
Posts: 337
Joined: 14 Apr 2021 21:48
Location: Earth

Re: Where are you better trees?

Post by ebla71 »

Speaking of trees - I'm quite happy with the look of the ones that come along with OpenGFX Trees, but the one thing that I currently consider the most negative impact on my gameplay experience is that I have been unable to find a good balance between "barren landscape" empty of any trees at all and "dense forest" which covers everything that is not railway, road, station, city, industry, or water (in "temperate" climate).

It might be due to my particular style of playing ("build & watch guy", relatively large 1024x1024 map and very long games, several hundred years and still going due to very liberal use of the "re-wind date" option from the "special" menue to stay in a certain "epoche", have been playing in the 1870-1875 range for half-a-year "real life" now) but I never managed to get anything satisfactory besides playing with the options that influence tree growths, usually turning it on for some years and when getting too dense, turning it off again until too little trees left, then back on and so on.

Is there any way to either significantly slow down (say, by a factor of 10-100) tree growth and disappearance or - preferrentially - completely "freeze" the number and placement of trees at a certain stage that looks nice to me, with further changes only by "bulldozing away" or planting trees manually?

Alternatively, allow individual trees to appear or disappear but still maintain a particular general "tree density" of a certain map?

Any good resource where the "tree planting and disappearance" mechanism of the game is described in detail? I recall some discussion some time back but could not find it anymore ...
Eddi
Tycoon
Tycoon
Posts: 8258
Joined: 17 Jan 2007 00:14

Re: Where are you better trees?

Post by Eddi »

kinda off-topic, but sadly there is no "balanced" tree growth. either you enable it, and everything is covered in trees after a while, or you disable it, and everything dies out eventually.

the only other way to prevent trees covering the whole map is to place farms. there can't be trees where there's farmland. (which is kinda realistic, honestly). the only thing missing there is meadows for grazing animals. and a height limit for large trees.
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Where are you better trees?

Post by kamnet »

ebla71 wrote: 16 Apr 2021 00:46 Is there any way to either significantly slow down (say, by a factor of 10-100) tree growth and disappearance or - preferrentially - completely "freeze" the number and placement of trees at a certain stage that looks nice to me, with further changes only by "bulldozing away" or planting trees manually?

Alternatively, allow individual trees to appear or disappear but still maintain a particular general "tree density" of a certain map?

Any good resource where the "tree planting and disappearance" mechanism of the game is described in detail? I recall some discussion some time back but could not find it anymore ...
Another alternative is to use the Logging Camp NewGRF, which will replace forest industries with a logging camp that will clear the trees off the map and sell it as lumber.
viewtopic.php?f=67&t=71330
ebla71
Transport Coordinator
Transport Coordinator
Posts: 337
Joined: 14 Apr 2021 21:48
Location: Earth

Re: Where are you better trees?

Post by ebla71 »

Thank you very much but that's not exactly what I'm looking for.

What I would like to have is a certain "tree density" maintained throughout a game. It does not necessarily need to be completely "static" (although that would also help), with trees only to be "bulldozed" or planted by player and otherwise not changing at all, but ideally rather a "dynamic equilibrium", that is for one tree disappearing somewhere another one grows elsewhere but total "tree population" is fixed.

I found this thread here viewtopic.php?t=83465 on a "Trees spreading patch" by MagicBuzz from 2018 but there was only one response and the GitHub link in that message does not seem to work anymore: https://github.com/SylvainDevidal/OpenT ... eSpreading

There was also a "Trees growth reduced" patch posted by Gedemon in 2009(!) viewtopic.php?f=33&t=45502 What is discussed there comes possibly closest to what I have in mind and there is also a mention by Eddi from 2014 further down line that
Tree handling happens in two places:

OnTick_Trees handles the random placement of trees on the map. This can be influenced by a setting.

TileLoop_Trees handles the growth of trees to their mature state, spreading into neighbouring tiles and killing trees which have been around for a while. This can currently not be influenced and is probably what you want. It would be fairly trivial to remove this function, which would freeze all trees. but that planted trees will not grow is probably not desired.
viewtopic.php?p=1129302#p1129302

However, seems like the discussion died out not shortly after. Any other important developments since then that I might have overlooked? Some of the thoughts in the latter thread exactly reflect what I'm looking for?
ebla71
Transport Coordinator
Transport Coordinator
Posts: 337
Joined: 14 Apr 2021 21:48
Location: Earth

Re: Where are you better trees?

Post by ebla71 »

Guided by the abovementioned text I started to look at

tree_cmd.cpp
tree_gui.cpp

which was not that easy given my "rusty" and rather archaic programming skills, if any. Still, I got at least some rough initial idea of the different ways trees get planted but could not identify the part of the code which is responsible for the trees disappearing?!? If there another *.cpp where this is handled or is "trees disappearing" simply something like "negative tree growth" - such as "loosing money" is also just "negative profit" :D
User avatar
jfs
Tycoon
Tycoon
Posts: 1750
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: Where are you better trees?

Post by jfs »

No you are in the right place.
TileLoop_Trees is the function responsible for trees growing and withering. Withering is just another part of the tree growth cycle. See the switch on GetTreeGrowth(tile), when the growth is 3 that means the tree is fully mature, and the tree will either spread or begin withering, based on a random roll.
When the growth is above 3 it means a tree is withering in the tile, and when it reaches 6 the tree disappears entirely.

An important part to understand about trees in OpenTTD is that when a tile is of type "trees", it can have multiple trees on it, but only one of those trees is growing/withering at a time. All the other trees on the tile are full size, and also only exist as a count of trees on the tile. The tile also does not store what types the other trees are, only the type of the "active" tree on the tile. This is why when you use the plant trees tool in-game, and keep clicking on the same tile, you get a tile full of different trees even though you were telling it to plant the same kind of tree every click.
Michi_cc
OpenTTD Developer
OpenTTD Developer
Posts: 619
Joined: 14 Jun 2004 23:27
Location: Berlin, Germany
Contact:

Re: Where are you better trees?

Post by Michi_cc »

Eddi wrote: 16 Apr 2021 01:19 kinda off-topic, but sadly there is no "balanced" tree growth. either you enable it, and everything is covered in trees after a while, or you disable it, and everything dies out eventually.
It's not exactly the same, but there is "Ingame placement of trees: Grow but don't spread". Means trees don't die out, but tree coverage remains static.
shaldoryn
Engineer
Engineer
Posts: 2
Joined: 14 Apr 2021 01:23

Re: Where are you better trees?

Post by shaldoryn »

Thank you kamnet, SAC's were those I was looking for, me happy now.
I agree with the trees density, my map is completely full of them.
But then with the "Grow but don't spread" I can now just clear out how I want and should be fine like that I can imagine..
ebla71
Transport Coordinator
Transport Coordinator
Posts: 337
Joined: 14 Apr 2021 21:48
Location: Earth

Re: Where are you better trees?

Post by ebla71 »

Thanks for the explanations. Now I simply need a compile environment to play around with the TileLoop_Trees function :D Do I get that right that the tree growth cycle (0 or 1 to 6) is stored in something like a 3-bit long "field" (with the rest of the byte used for something else) and therefore cannot easily be extended further (more stages)? [dusting off old programming knowledge]

But even without that, the mentioned
"Ingame placement of trees: Grow but don't spread"
seems to come close to what I want. Where can you change that option? In OTTD 1.10.1 that I am using under "Settings -> Environment -> In game placement of trees" there are only three options: "None", "Only in rain forests", and "Everywhere" Need a newer version or a special patch or "branch"?
ufiby
Traffic Manager
Traffic Manager
Posts: 158
Joined: 18 Nov 2017 13:58

Re: Where are you better trees?

Post by ufiby »

Now there is no need to add a patch and other ways to supplement any
Download OpenTTD versions from 1.11.0
tree.png
tree.png (9.61 KiB) Viewed 2887 times
Happy now!
ebla71
Transport Coordinator
Transport Coordinator
Posts: 337
Joined: 14 Apr 2021 21:48
Location: Earth

Re: Where are you better trees?

Post by ebla71 »

Alright :) I did not change to OTTD 1.11.0 so far since I'm playing a really long game (for more than 7 months - in "real life") and want to be sure it goes not get broken. Usually wait for the 1st or 2nd minor update before I change to latest version but this might be a big incentive to indeed give 1.11 a try
LaChupacabra
Route Supervisor
Route Supervisor
Posts: 385
Joined: 08 Nov 2019 23:54

Re: Where are you better trees?

Post by LaChupacabra »

ebla71 wrote: 17 Apr 2021 19:50 Alright :) I did not change to OTTD 1.11.0 so far since I'm playing a really long game (for more than 7 months - in "real life") and want to be sure it goes not get broken. Usually wait for the 1st or 2nd minor update before I change to latest version but this might be a big incentive to indeed give 1.11 a try
In this case, most likely your entire map is already overgrown with trees. :D

At 99%, you have nothing to worry about (unless you are play with inflation). As for the tree growth blocking feature, it was added in 1.10.0, so you can use it anyway. The disadvantage of this solution is that once the tree growth is turned off, the trees will never disappear. So if you already have too many trees, they will stay forever, or you will have to remove them manually.
shaldoryn wrote: 14 Apr 2021 01:36 I see on many screenshots nicer trees than the original ones.. but, no matter all the NewGRF's I've explored, or the searches I did, I can't figure out where those come from.
I'm well speaking about the landscape generated trees, not objects of tree that you place as decor tile.
I'm very interested in the pin trees actually.

As for interesting add-ons with trees that are not available in the game and that are hard to find at all:

Image
Top left corner
vvv
CZTR_Tree_set-1.0.1.tar
(5.52 MiB) Downloaded 132 times
(put in: documents / OpenTTD / content_download / newgrf)

Top right corner
vvv
testw.grf
(294.62 KiB) Downloaded 153 times
(put in: documents / OpenTTD / content_download / newgrf)
(green pines are available in arctic climates only, for green grass in arctic use OpenGFX + Landscape)

Bottom left corner
Wasteland - Available in the game

Bottom right corner
OpenGFX + Trees - Available in the game (I recommend it especially for tropical climate / In this add-on you can set exactly which trees will be used)
I am sorry for may English. I know is bed.
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: Ahrefs [Bot] and 10 guests