duane wrote:This sounds great. However, wouldn't it be simpler and more efficient to remove the abms altogether and make leaf decay an on_destruct function of tree-type nodes?
duane wrote:Another question is -- how much time does leaf decay actually take at the moment? Even when I turn it completely off for every node, it doesn't seem to make much difference on my system.
Gael de Sailly wrote:The reason is not only to save time. It should improve the way leaves are removed. Instead of removing the leaves that are at more than n nodes from the trunk, it removes leaves that have been spawned with the tree, even if they are close to another tree, so it better respects the shape of the nearby trees, instead of leaving an ugly square of leaves next to the tree. In fact, that's the most important thing for me. The time saving argument has only made me think about it.
duane wrote:If you have a schematic that over-writes one tree with another, which probably happens a lot in the mapgen, wouldn't you still get ugly holes when you remove the newer of the two?
duane wrote:Wouldn't it be simpler and more efficient to remove the abms altogether and make leaf decay an on_destruct function of tree-type nodes?
BrandonReese wrote:duane wrote:This sounds great. However, wouldn't it be simpler and more efficient to remove the abms altogether and make leaf decay an on_destruct function of tree-type nodes?
That's an interesting avenue to explore. If you were to find all of the connected nodes that might not be very efficient. The other option would be to use find nodes in area to check an area for other tree nodes, and if no tree nodes are found then use find nodes in area to find all leaf nodes and decay them.
duane wrote:the only advantage is time
Gael de Sailly wrote:The leafdecay algorithm consists in checking that a tree takes place at this position. So, every leaves block belongs to one tree. This solves a problem that I've very often seen: when you cut a trunk, the leaves falls, but if there is another tree next to it, most of the leaves don't fall.
SegFault22 wrote:duane wrote:the only advantage is time
...Gael de Sailly wrote:The leafdecay algorithm consists in checking that a tree takes place at this position. So, every leaves block belongs to one tree. This solves a problem that I've very often seen: when you cut a trunk, the leaves falls, but if there is another tree next to it, most of the leaves don't fall.
Is this not also an advantage?
duane wrote:SegFault22 wrote: ~ka-snip~
I was referring to my idea sucking, not the original post.
Users browsing this forum: No registered users and 7 guests