From: Peter Wang Newsgroups: comp.os.msdos.djgpp Subject: Re: DJGPP's random functions. Date: Sat, 03 Apr 1999 04:05:51 +1000 Organization: Alphalink Lines: 10 Message-ID: <370506FF.A5266669@psynet.net> References: <3705018e AT news DOT ismi DOT net> NNTP-Posting-Host: ppp25-14-melbourne.alphalink.com.au Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: news.alphalink.com.au 923112408 17907 202.161.98.56 (3 Apr 1999 04:06:48 GMT) X-Complaints-To: usenet AT news DOT alphalink DOT com DOT au NNTP-Posting-Date: 3 Apr 1999 04:06:48 GMT X-Mailer: Mozilla 4.06 [en] (Win98; I) To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com > Ike Gingerich wrote: > > I noticed that the functions that come with DJGPP for generating > random numbers always spit out the random numbers in the same sequence > each time the program is run. This bothered me becase for games I Look up srandom in the docs to seed the generator at the start of your program. eg. srandom(time(NULL));