What is preSLAG.awk
-------------------

It's a GAWK script which takes an Invisiclues file, such as the ones
contained in ftp://ftp.ifarchive.org/if-archive/infocom/hints/invisiclues ,
as input, and produces as output what is essentially a copy of the input
file, but with formatting tags for the hint compiler SLAG. preSLAG tries
to be as complete as possible, and for some very simple Invisiclues files,
it may actually solve the task almost completely, but for most input files
the output file will need a little or a lot of human editing before SLAG
can use it to produce a good hint program.

Usage: gawk -f preSLAG.awk infile > outfile

Limitations of preSLAG.awk:
---------------------------

The title "Invisiclues for Xxx Yyy" where "Xxx Yyy" is the game title,
won't be capitalised correctly for titles that contain multiple words,
unless it was capitalised correctly in the header of the Invisiclues
file. This must be changed manually after preSLAG has been run.

Menus with submenus (apart from the main menu) aren't treated properly.
These must be edited by hand after preSLAG has been run.

Items that are phrased somewhat differently in the menu from which
they are linked will have to be changed manually to match the link,
either before or after running preSLAG.

Menus that hold too many alternatives to fit on an 80x25 screen aren't
automatically split up into sections. This must be done by hand after
preSLAG has been run.

All .TEXT sections are also enclosed in .FIX / .UNFIX. Check this from
case to case manually, after preSLAG has been run.

Questions (".HINT":s) that take up more than one row aren't considered
as questions. Workaround: Concatenate rows in the source file before
running preSLAG. Also check that the question looks good on an 80 column
screen. If it doesn't, rephrase it slightly to make it shorter.

Clues that should really contain line breaks and/or fixed width fonts
to make sense, get ugly. It takes a human's hand and judgment to fix the
formatting and try to make the clue sensible.

There is certainly some text in some of the Invisiclues files that will
confuse preSLAG. However, all text that is in the original file will also
be in the output file, in the same order, with the addition of the tags.

Since all lines present in the original Invisiclues file are also present
in the output file, it's inevitable that some text, such as the asterisk
lines, must be manually removed after preSLAG has been run.

Please note that while preSLAG should indeed save you a lot of tedious
typing and editing, you need to check the end result carefully to
determine that the z5-file displays all menus, hints and clues, and
that they are presented properly. preSLAG can never be as smart as a
human.

