[TOGoS][0.17.7] autoplace peak: 3+ climate dimension ranges breaks distribution

This subforum contains all the issues which we already resolved.
User avatar
Earendel
Factorio Staff
Factorio Staff
Posts: 716
Joined: Sun Nov 23, 2014 11:57 am
Contact:

[TOGoS][0.17.7] autoplace peak: 3+ climate dimension ranges breaks distribution

Post by Earendel »

When using an autoplace peak on trees, if I have 2 climate dimensions specified, such as water_ and aux_ or water_ and temperature_ then the resulting distribution is as expected.

If a 3rd dimension range specified ( water_ aux_ and temperature_) then the distribution breaks and it vastly overshoots the specified water range.

In the game the most obvious sigh that things are wrong (apart from the mass rainbow forest) is that wetland trees are spawning heavily in dryland, but a screenshot doesn't illustrate the problem very well if you don't know where the trees are supposed to be. A crude diagram is attached showing roughly what happens.

I have removed most of the noise influence to rule that out, also the fact that if I remove aux_ from the equation it behaves more as expected.
This behavior is different to 0.16 where I could use 3 climate dimensions without problems.

I've tried using a probability_expression for the placement and trees go in the right general area, but the density is way too high but max_probability and random_probability_penalty don't seem to affect it if a probability_expression is used.
Attachments
axis problem diagram.jpg
axis problem diagram.jpg (242.69 KiB) Viewed 2520 times

TOGoS
Former Staff
Former Staff
Posts: 97
Joined: Fri Jun 24, 2016 2:29 pm
Contact:

Re: [TOGoS][0.17.7] autoplace peak: 3+ climate dimension ranges breaks distribution

Post by TOGoS »

The peak/dimension-based autoplace specifications being hard to control are the reason probability_expression was added to bypass all of that stuff.

max_probability and random_probability_penalty do not have any effect if probability_expression is provided. That is by design.

That said, the behavior of otherwise identical autoplace specifications wasn't supposed to change between 0.16 and 0.17. Could you provide the data for the autoplace specification that demonstrates the discrepancy?

TOGoS
Former Staff
Former Staff
Posts: 97
Joined: Fri Jun 24, 2016 2:29 pm
Contact:

Re: [TOGoS][0.17.7] autoplace peak: 3+ climate dimension ranges breaks distribution

Post by TOGoS »

Derp. Integer division of 2 by the number of peaks when calculating peak influence results in 0 when there are more than 2 peaks.

None of the autoplace specifications in vanilla use more than 2 peaks, apparently, which is why this wasn't caught.

Should be fixed for 0.17.9.

Thanks for the report!

User avatar
Earendel
Factorio Staff
Factorio Staff
Posts: 716
Joined: Sun Nov 23, 2014 11:57 am
Contact:

Re: [TOGoS][0.17.7] autoplace peak: 3+ climate dimension ranges breaks distribution

Post by Earendel »

That's great news, thanks.

Post Reply

Return to “Resolved Problems and Bugs”