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?
-
I believe you need to work at Mojang to know the full answer to that question. :P– Billy ONealOct 21, 2011 at 17:13
-
5@BillyONeal or simply read Mojang's blog.– user4595Oct 21, 2011 at 17:19
-
1Blog post: notch.tumblr.com/post/3746989361/terrain-generation-part-1– PubbyOct 21, 2011 at 18:50
1 Answer
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.
-
Good point, though has anyone tried giving the same seed to Minecraft more than once to see if the terrain is really the same (or even just "approximately" the same)? Oct 21, 2011 at 17:15
-
2@FrustratedWithFormsDesigner Notch (the designer of the game) says that the generated world will be identical if the same seed is given.– user4595Oct 21, 2011 at 17:16
-
-
5The only times the terrain changes when the same seed is input is if the generation algorithm changes (which is just about every major update...). It's worth pointing out that the terrain generation is commonly called procedural generation– thedaianOct 21, 2011 at 18:09
-
2Minecraft also runs a hash function to transfer string seeds into numbers.– PubbyOct 21, 2011 at 18:52