Complete.Org: Mailing Lists: Archives: freeciv-dev: December 1999:
[Freeciv-Dev] patch: rand module / code cleanup (PR#204)
Home

[Freeciv-Dev] patch: rand module / code cleanup (PR#204)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv-dev@xxxxxxxxxxx
Cc: bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] patch: rand module / code cleanup (PR#204)
From: David Pfitzner <dwp@xxxxxxxxxxxxxx>
Date: Sat, 25 Dec 1999 04:02:46 -0800 (PST)

Hi,

I had some free time recently so I made some patches for a
few things I wanted to do long ago.

This patch doesn't have any user-visible changes, but just
tidies the code up a bit.  It moves the myrand() stuff to a 
separate module, common/rand.[ch], and make some things 
slightly nicer IMO:  

Wraps random state variables up into a struct; avoids using 
globals/extern to save/restore random state in savefile; 
more flexible method to have multiple concurrent random 
sequences (replaces old save_restore_random() with 
get_myrand_state() and set_myrand_state()).

-- David

Attachment: rand_module1.diff.gz
Description: GNU Zip compressed data


[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] patch: rand module / code cleanup (PR#204), David Pfitzner <=