In minecraft, before creating a world you have an option to input a seed. The algorithm takes the seed and creates a completely unique world. How does this work?
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:
Here's how it works:
- Anybody can ask a question
- Anybody can answer
- The best answers are voted up and rise to the top
It gives the seed to a pseudorandom number generator (PRNG) and uses that PRNG to generate the world.
Giving the same seed will give the same sequence from the PRNG and thus generate the same world.