Newsgroups: rec.arts.int-fiction
Path: nntp.gmd.de!news.rwth-aachen.de!news.rhrz.uni-bonn.de!RRZ.Uni-Koeln.DE!news.duesseldorf.ecrc.net!news.hamburg.ecrc.net!news.berlin.ecrc.net!news.ecrc.de!02-newsfeed.univie.ac.at!newsfeed.sunet.se!news00.sunet.se!sunic!nntp.coast.net!howland.erols.net!netcom.com!erkyrath
From: erkyrath@netcom.com (Andrew Plotkin)
Subject: Re: [Z-machine] save formats
Message-ID: <erkyrathDyIux3.Avr@netcom.com>
Organization: NETCOM On-line Communication Services (408 261-4700 guest)
X-Newsreader: TIN [version 1.2 PL1]
References: <VA.00000009.000adcbd@104312.2206> <VA.0000000a.0031fbde@104312.2206>
Date: Mon, 30 Sep 1996 01:31:51 GMT
Lines: 47
Sender: erkyrath@netcom20.netcom.com

Bryan Scattergood (104312.2206@compuserve.com) wrote:
> The current format I use is missing a magic number as well.  And I 
> really need the original game name to be in there as well; that allows 
> some neat tricks with double-click loading.

> I guess what I want is a format which

> 1. compresses at least as well as the current one
> 2. is portable across machines (no endian/int-size issues)
> 3. stores a magic number identifying the game
> 4. is easily recognisable
> 5. can store the game name
> 6. is extensible with other information (fonts, colours, window info)
> 7. has save/restore code as small as possible

> Actually (6) probably takes care of (5).

Yes. Remember that, like font/color/window info, a game name is a
system-dependent resource! Its format depends on what your OS is. Not
everybody uses pathnames. On the Mac, for example, it should be an Alias
Manager record. (You can put together something that looks like a
pathname, but then you don't get the advantage of all the Alias Manager 
magic -- like automatically finding the file even if it's moved, or 
changed names.)

(As I adumbrated in an earlier post, I may add Alias Manager records to 
the MaxZip save format anyway. I can do this without changing the format 
at all, because Mac files have a resource fork which is entirely 
independent of the data in the file.)

>  (7) is important.  The 
> current code I use has a footprint of about 4K and needs 512 bytes of 
> static workspace.  I'd like to make this smaller (programming for the 
> Psion has distorted my priorities :-)

> Anyone have a format which meets all of these requirements?  Or about 
> to volunteer to design one before I have to?

I've got enough on my plate right now. :-) Feel free. (I'm not promising 
to adopt it, of course. :-)

--Z

-- 

"And Aholibamah bare Jeush, and Jaalam, and Korah: these were the
borogoves..."
