simon-svn: puzzles: simon

tartarus-commits at tartarus-commits at
Mon May 16 19:57:11 BST 2005

SVN root:       svn://
Changes by:     simon
Revision:       5788
Date:           2005-05-16 19:57:09 +0100 (Mon, 16 May 2005)

Log message (30 lines):
The game IDs for Net (and Netslide) have always been random seeds
rather than literal grid descriptions, which has always faintly
annoyed me because it makes it impossible to type in a grid from
another source. However, Gareth pointed out that short random-seed
game descriptions are useful, because you can read one out to
someone else without having to master the technology of cross-
machine cut and paste, or you can have two people enter the same
random seed simultaneously in order to race against each other to
complete the same puzzle. So both types of game ID seem to have
their uses.

Therefore, here's a reorganisation of the whole game ID concept.
There are now two types of game ID: one has a parameter string then
a hash then a piece of arbitrary random seed text, and the other has
a parameter string then a colon then a literal game description. For
most games, the latter is identical to the game IDs that were
previously valid; for Net and Netslide, old game IDs must be
translated into new ones by turning the colon into a hash, and
there's a new descriptive game ID format.

Random seed IDs are not guaranteed to be portable between software
versions (this is a major reason why I added version reporting
yesterday). Descriptive game IDs have a longer lifespan.

As an added bonus, I've removed the sections of documentation
dealing with game parameter encodings not shown in the game ID
(Rectangles expansion factor, Solo symmetry and difficulty settings
etc), because _all_ parameters must be specified in a random seed ID
and therefore users can easily find out the appropriate parameter
string for any settings they have configured.

Modified files:
U   puzzles/cube.c
U   puzzles/fifteen.c
U   puzzles/gtk.c
U   puzzles/midend.c
U   puzzles/net.c
U   puzzles/netslide.c
U   puzzles/nullgame.c
U   puzzles/osx.m
U   puzzles/pattern.c
U   puzzles/puzzles.but
U   puzzles/puzzles.h
U   puzzles/rect.c
U   puzzles/sixteen.c
U   puzzles/solo.c
U   puzzles/twiddle.c
U   puzzles/windows.c


More information about the tartarus-commits mailing list