[ScryMUD] SVN Commit Info r848 - trunk/mud/grrmud/server
scrymud at wanfear.com
scrymud at wanfear.com
Thu Jul 13 12:28:28 PDT 2006
Author: eroper
Date: 2006-07-13 12:28:27 -0700 (Thu, 13 Jul 2006)
New Revision: 848
Modified:
trunk/mud/grrmud/server/misc.cc
Log:
According to Loki (Justin) re-seeding the RNG is a bad idea. It could be
contributing to the "Streaky"ness, etc. of the RNG we've been experiencing.
Modified: trunk/mud/grrmud/server/misc.cc
===================================================================
--- trunk/mud/grrmud/server/misc.cc 2006-07-12 00:24:45 UTC (rev 847)
+++ trunk/mud/grrmud/server/misc.cc 2006-07-13 19:28:27 UTC (rev 848)
@@ -205,13 +205,6 @@
int d(const int num_rolls, const int dice_sides) {
int rtvalue = 0;
- static int times;
-
- if(times >= 255){
- srand(time(NULL));
- times = 0;
- }
- times++;
for (int i = 0; i<num_rolls; i++) {
rtvalue += 1 +(int)((rand() * (float)(dice_sides)) / (RAND_MAX + 1.0));
}//for
More information about the ScryMUD
mailing list