Terrain, staying the same?

How can you create terrain without it randomizing the out come? Basically, in the Flag Rush tutorials they randomize the terrain. Meaning it doesn't stay the same.





Also is there an easier way to create terrain, and how can I make it stay the same?

Search for terrain using heightmaps.

Also look for the JGN (Java Gaming Network) tutorials.  For networking, he specifically modified the FlagRush tutorial to use a fixed heightmap instead of random (so both network clients are working with the same terrain).

If you want random terrain that is predictable every time you need to use a routine that allows you to set a seed for the random numbers to generate the height map. This means that you will always get the same result if the same seed is used.

Not all the heightmap generating code works this way tho :-



FaultFractalHeightMap , FluidSimHeightMap and  HillHeightMap use java.util.Random and can be seeded to produce the same terrain every time.



MidPointHeightMap (as used by the flagrush tutorials) and ParticleDepositionHeightMap use Math.random and so (as far as I know) can't be seeded so will give a different terrain each time.