Thread: Repeat Galaxies
View Single Post
  #7  
Old November 3rd, 2000, 01:19 AM
Instar's Avatar

Instar Instar is offline
Major
 
Join Date: Aug 2000
Posts: 1,246
Thanks: 0
Thanked 0 Times in 0 Posts
Instar is on a distinguished road
Default Re: Repeat Galaxies

Hmm In C/C++ you use the srand and stuff to get random numbers.
Usually the way I do it is to call the time function, put that into the seed, and call up the random number (that method is probably the best for normal uses IMO)
Then you can modulo the number down to whatever size
__________________
When a cat is dropped, it always lands on its feet, and when toast is dropped, it always lands with the buttered side facing down. I propose to strap buttered toast to the back of a cat. The two will hover, spinning inches above the ground. With a giant buttered cat array, a high-speed monorail could easily link New York with Chicago.
Reply With Quote