Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
clarify my own contributions to mersenne.js
  • Loading branch information
jamis committed Mar 22, 2015
1 parent 00d58d0 commit f141deb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/mersenne.js
@@ -1,4 +1,6 @@
/*
From Sean McCullough:
I've wrapped Makoto Matsumoto and Takuji Nishimura's code in a namespace
so it's better encapsulated. Now you can have multiple random number
generators and they won't stomp all over eachother's state.
Expand Down Expand Up @@ -136,6 +138,7 @@
return y >>> 0;
}

/* The following methods were added by Jamis Buck */
MersenneTwister.prototype.random = function() {
if (arguments.length > 0)
return this.genrand_int32() % arguments[0];
Expand Down

0 comments on commit f141deb

Please sign in to comment.