Fixed randomness
Fixed random generator
Merge pull request #3 from seeker89/master

Fixed randomness problems