LWJGL Forum

Programming => OpenGL => Topic started by: Setlock on December 06, 2016, 00:02:38

Title: Pseudo random number Algorithm
Post by: Setlock on December 06, 2016, 00:02:38
Hello again everyone, i'm trying to make a pseudo random algorithm where you input a number(seed) and it will give u a bunch of x and y coordinated to make a good looking world. If anyone can help that would be great!
Title: Re: Pseudo random number Algorithm
Post by: abcdef on December 06, 2016, 08:27:31
Just use a normal random number generator and run it twice and multiply the random numbers (assuming between 0 and 1) by the screen width and height.
Title: Re: Pseudo random number Algorithm
Post by: Cornix on December 06, 2016, 09:20:58
The built in of the JDK is pretty good. Just look at that code if you really want to build your own.