Skip to content

Instantly share code, notes, and snippets.

@gastonambrogi
Created July 11, 2019 17:26
Show Gist options
  • Save gastonambrogi/f5654dd110bfe7a5b040f2d81f4e48f1 to your computer and use it in GitHub Desktop.
Save gastonambrogi/f5654dd110bfe7a5b040f2d81f4e48f1 to your computer and use it in GitHub Desktop.
Function that generates a random by a seed
function random(seed) {
var x = Math.sin(seed) * 10000;
return x - Math.floor(x);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment