Well you didn't murder a kitten or anything. Its just going to slow down your code while performing a redundant task. People like me get paid good money to correct code where people have done similar...
Type: Posts; User: master5001
Well you didn't murder a kitten or anything. Its just going to slow down your code while performing a redundant task. People like me get paid good money to correct code where people have done similar...
You should not be reseeding your pseudo-random number pool like that, Newton. Perhaps that is why "your way doesn't work, master5001." You should uncommment the first srand(time(NULL)) and comment...
I doubt this guy is writing a black jack server... but for those of you who are reading this thread because you have the initiative to utilize the forum's search function, God bless you. Here is...
Just do this:
Example:
#include <time.h>
...
srand(time(NULL));
Perhaps you should do something like....
Example:
randnum = (rand() >> 16) & 7;