From: mlevis@ringer.cs.utsa.edu (Mike Levis)
Newsgroups: comp.sys.ibm.pc.games
Subject: Re: INFOCOM: Boot -> Dos disk util?
Date: 6 Sep 92 08:55:37 GMT
Organization: University of Texas at San Antonio

In article <blasius.50.715520476@gmd.de> blasius@gmd.de (Volker Blasius) writes:
>
>I don't know of a conversion program, but I once converted a boot disk by 
>hand. I'll outline the procedures:
>
>- The old Infocom games consist of 2 files, an interpreter (.exe) and a
>  data file (.dat ?) that constitutes the game in question. I couldn't
>  convert the interpreter, but I found the data file, copied it to the
>  hard disk, and found an interpreter in my collection that worked with
>  the copied data file. I forgot which game it was, but I can look it up
>  it you need to know.
>- The boot disk is a one-sided 180k diskette, so you need a program that
>  can read this disk at the track level. I used ANADISK by Sydex, available
>  on SIMTEL20. Look at a data file of a game you have on your hard disk,
>  especially at the patterns of the beginning, and find the beginning of
>  the data file on the boot diskette by staring at the data. Then copy from
>  there to the end of the diskette surface (ANADISK can do that) to game.dat
>  on your hard disk. (I seem to remember that the diskette can't be read by
>  DOS because some sectors (not in the data part) are longer than 512.)
>- Patch an appropriate interpreter with a hex editor to point to the name
>  you gave to your data file. To find out, which interpreter works, copy
>  them one by one to the directory where your new data file is, rename the
>  data file to the name of the interpreter (.dat, of course), and try to
>  run it.
>- BTW, the data files are machine independent; a friend of mine told me he
>  runs Atari data files with a DOS interpreter.
>
>Hope it works for you, too!
>
>Volker

Excellent information, Volker!  I hacked the following.  It
reads the data portion of an Infocom IBM boot-from-disk game
and writes a DOS-compatible data file.

begin------------------------------------------------------------
A 100
MOV	AH,3C			; create "C:\INFOCOM.DAT" on C:
SUB	CX,CX
MOV	DX,0151
INT	21
MOV	[014E],AX
MOV	BYTE PTR [0150],06	; for each track 6 to 39...
CALL	0129			;    copy data portion of
INC	BYTE PTR [0150]		;    the boot-from-disk game
CMP	BYTE PTR [0150],27	;    to "C:\INFOCOM.DAT"
JBE	0111
MOV	AH,3E			; close "C:\INFOCOM.DAT"
MOV	BX,[014E]
INT	21
INT	20			; finish
MOV	AH,0B
INT	21
MOV	AX,0208			; read data portion from
MOV	CH,[0150]		;   the boot-from-disk game
MOV	CL,01
SUB	DX,DX
MOV	BX,0160
INT	13
JB	0129
MOV	AH,40			; write it to "C:\INFOCOM.DAT"
MOV	BX,[014E]
MOV	CX,1000
MOV	DX,0160
INT	21
RET
DW	0
DB	0
DB	"C:\INFOCOM.DAT",0

N IC_COPY.COM
R CX
60
W
Q
------------------------------------------------------end

Before you begin:
   1.  make sure you have an IBM-compatible boot-from-disk
       Infocom game (of course).
   2.  make sure you have a DOS-compatible Infocom game
       with an interpreter version of "L", "M", or "N".
       Other versions don't seem to work.  Check the
       version with the "$verify" command.

What to do:
   1.  cut out the above script, call it IC_COPY.SCR .
   2.  create IC_COPY.COM by running the above through
       debug as follows:
       DEBUG < IC_COPY.SCR
   3.  insert your boot-from-disk game into drive A:
   4.  type IC_COPY at the C:> prompt.  This program
       will copy sectors 6 through 39 (the data portion)
       of the boot-from-disk game and create a DOS file
       on drive C: called INFOCOM.DAT .
       (Since IC_COPY.COM is just a hack, it does not
       have much flexibility or error checking, and
       drive A: must have a disk in it, and it writes
       only to the C: drive.)
   5.  rename INFOCOM.DAT to some name similar to
       the boot-from-disk game.  You should move
       this file to a directory with an interpreter
       and then change to that directory.
   6.  play the game by running an "L", "M", or "N"
       interpreter with the command switch /G<datafilename>
   7.  go to step 3 if you have another game to convert.

Example:
   Suppose your boot-from-disk game is called "Cutthroats"
   and your interpreter comes from "Zork III".
   Put the "Cutthroats" disk in drive A: and type ``IC_COPY''
   at the C: prompt.  Then type ``REN INFOCOM.DAT CUTTHROA.DAT''
   at the C: prompt.  Now type ``ZORK3 /GCUTTHROA.DAT'' and
   play.

Note:
   Doing a $verify from a game will result in the interpreter
   giving a message that the data is bad, but actually the
   game seems to run fine.

Help this helps someone...
-- 
==== Mike Levis   mlevis@ringer.cs.utsa.edu ====
::   ftp ftp-os2.nmsu.edu (128.123.35.151)    ::  .--.
::   for OS/2 software & information.  Get    :: (OS/2)
:::: the OS/2 FAQL in dir /pub/os2/all/faq :::::  ~--~