Useful information about world seeds -- how to get closer to the world you want!

Looking at this post, and its mention of the upper and lower digits of that 32-bit integer, I interpreted that as having two possibilities:

  1. The number is used to create the heightmaps, and then a certain part of the number is used to pick coordinates for a section of that heightmap to pull from when determining the output within an area.
  2. The heightmaps are created from the seed, and then overlayed with the game map directly.

I was assuming it was the latter, since that’s the simplest and most logical implementation. However, I have seen more complex versions where, instead of simply using the current map coordinate as the heightmap coordinate, the game does weird and wonderful extra steps to further “roughen” the output. In the case I’m thinking of, the game looked at what quadrant of the map (on a cartesian plane) that coord was in, and then used that to pick 1/4 of the seed as the input for a second pass of noise generation.

But, even assuming the simplest option, there are clear links between parts of the seed and their effects on the generation. I don’t claim to know how exactly it works, but it seems that the different heightmaps “favour” one end of the integer. I would guess (and again, my guesses aren’t worth much) that there’s a “multiply by negative” in one or some of the simplex algorithms/equations (IDK which is the proper term here) but not the others, possibly just to further separate the results. So, even though the whole number is important for the end result, if my guess is close to accurate then particular combinations can be traced back to specific inputs.

Adding 1000 to the seed would result in a very different map, yes, but ticking over only the largest bit to cause a wrap-around would create an identical (or perhaps not quite identical?) seed. But that’s just the conversion of the entered number to bits; my goal here is wrapping around the simplex generator itself so that the heightmap produced conforms to a set expectation. If adding 1000 repeatedly gives a consistent result, then after X number of repetitions a pattern should emerge.

What I’m talking about is tracing the effects back, and loading the seed with numerals based upon the knowledge of what the simplex mapping will convert that to. Even though the game reads the seed as a whole, the order of the numerals is still important – there is a finite number of possibilities, even though it’s really really large it’s not random. Figuring out the output of each seed obviously isn’t practical; and it would be much faster to automate the process and have a computer spit out every possible result. But what I’m interested in isn’t exact results, it’s the patterns. The algorithms don’t change, so if there’s a pattern that creates, say, large plains with no trees, that’s useful for players to know about. Then it’s down to trial and error to get the best possible result.

If the player only cares about particular features, e.g. they want to target large plains with no trees but don’t care about water or where the mountains are, then there will be certain seed inputs which create that a set of large plains with no trees on them; if there’s a visible pattern running through those inputs then that becomes a general rule they can apply. The rules may not combine well, since that’s not how the simplex algorithm works; but it should still be possible to control at least one variable at a time if the pattern can be established. Now, it’s entirely possible that any such pattern won’t show up readily, or that there is no such pattern; but there’s no logical reason for Radiant to go out of their way with excessive randomisation… so I’m hopeful that those patterns will exist. Depending on what the simplex noise generator does with the input, the process may be straightforward or downright impossible.

But, if it’s possible, then the goal is to create a guideline based upon the inputs, not the method. I mean, I’m banking on the possibility that figuring this out creates a straightforward list of generation rules; one which is simpler to learn than going through the process of learning about noise generation and how to apply the heightmaps. If I knew that, I would have applied it to a mod by now LOL!

Again though, thanks for indulging my curiosity, ignorance and imagination. Together they can be a dangerous combination… but, that’s how I come up with the motivation to go spend the time and effort learning new stuff to put those crazier and less-informed thoughts into practice.