-
Notifications
You must be signed in to change notification settings - Fork 4
/
appb.html
139 lines (117 loc) · 6.13 KB
/
appb.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
<!DOCTYPE html>
<html>
<head>
<title>The Z-Machine Standards Document</title>
<link rel="stylesheet" type="text/css" href="zspec.css">
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
</head>
<body class="appendix">
<img class="icon" src="images/iconab.gif" alt="">
<h1>Appendix B. Conventional contents of the header</h1>
<p>The header table in <a href="sect11.html">section 11</a>
details everything the interpreter needs to know
about the header's contents. A few other slots in the header are meaningful
but only by convention (since existing Infocom and Inform games write them).
These additional slots are described here.
</p>
<p>As in <strong>§</strong> 11, "Hex" means the address, in hexadecimal; "Len" the length in bytes; "V" the
earliest version in which the feature appeared; "Dyn" means that the byte
or bit may legally be changed by the game during play (no others may legally
be changed by the game); "Int" means that the interpreter may (in some
cases must) do so.
</p>
<table>
<caption><strong>Conventional usage of unspecified header memory</strong></caption>
<tr><th>Hex </th><th>Len</th><th>V </th><th>Dyn </th><th>Int </th><th>Contents</th>
<tr><td> 1 </td><td>1</td><td>1</td><td> </td><td> </td><td><em>Flags 1:</em></td></tr>
<tr><td> </td><td> </td><td><I>3</I> </td><td> </td><td> * </td><td> Bit 3: The legendary "Tandy" bit (see note)</td></tr>
<tr><td> 2 </td><td>2</td><td>1 </td><td> </td><td> </td><td> Release number (word)</td></tr>
<tr><td> 10 </td><td>2</td><td>1 </td><td> * </td><td> </td><td> <I>Flags 2:</I></td></tr>
<tr><td> </td><td> </td><td><I>3</I> </td><td> </td><td> </td>
<td> Bit 4: Set in the Amiga version of The Lurking Horror so presumably to do with sound effects?</td>
</tr>
<tr><td> </td><td> </td><td>? </td><td> ? </td><td> * </td>
<td> 10: Possibly set by interpreter to indicate an error with the printer during transcription</td>
</tr>
<tr><td> 12 </td><td>6</td><td>2 </td><td> </td><td> </td><td> Serial code (six characters of ASCII)</td></tr>
<tr><td> </td><td> </td><td>3 </td><td> </td><td> </td><td> Serial number (ASCII for the compilation date in the form YYMMDD)</td></tr>
<tr><td> 38 </td><td>8</td><td>6 </td><td> </td><td> * </td>
<td>Infocom used this as 8 bytes of ASCII: the player's user-name on their own mainframe,
useful to identify which person played a saved-game
(however, the bytes are all 0 in shipped story files)
</td>
</tr>
<tr><td> 3C </td><td>4</td><td> </td><td> </td><td> </td>
<td>Inform 6 stores 4 bytes of ASCII here, giving the
version of Inform used to compile the file:
for instance, "6.11".</td>
</tr>
</table>
<ol>
<li>In Versions 1 to 3, bits 0 and 7 of 'Flags 1' are unused. (The meaning
of bit 2 has recently been discovered: see
<a href="sect11.html">section 11</A>.) In later
Versions, bits 0, 6 and 7 are unused. In 'Flags 2', bits 9 and 11-15 are
unused. Infocom used up almost the whole header: only the bytes at <B>$32</B>
and <B>$33</B> are unused in any Version, and those are now allocated for
standard interpreters to give their Revision numbers.
</li>
<li>Some early Infocom games were sold by the Tandy Corporation, who
seem to have been sensitive souls. 'Zork I' pretends not to have sequels
if it finds the Tandy bit set. And to quote Paul David Doherty:
<blockquote>
In 'The Witness', the Tandy Flag can be set while playing the game,
by typing <strong>$DB</strong> and then <strong>$TA</strong>.
If it is set, some of the prose will be
less offensive. For example, "private dicks" become "private eyes",
"bastards" are only "idiots", and all references to "slanteyes" and
"necrophilia" are removed.
</blockquote>
We live in an age of censorship.
</li>
<li>For comment on interpreter numbers,
see <strong>§</strong> 11. Infocom's own interpreters
were generally rewritten for each of versions 3 to 6. For instance,
interpreters known to have been shipped with the Macintosh gave version
letters B, C, G, I (Version 3), E, H, I (Version 4), A, B, C (Version 5) and
finally 6.1 for Version 6. (Version 6 interpreters seem to have version
numbers rather than letters.) See the "Infocom fact sheet" for fuller
details.
</li>
<li>Inform 6 story files are easily distinguished from all other story files
by their usage of the last four header bytes. Inform 1 to 5 story files
are best distinguished from Infocom ones by the serial code date: anything
before 930000 is either an Infocom file, or a fake.
(The author of 'Jigsaw' is tempted to compile a millenial version with
serial code 991231 when the time comes, but then the next day serial codes
will clock over to 000101. The decision of how to continue serial codes
past the year 2079 is deferred to a future revision of this Standard.)
Clearly there is no point going to any trouble to prevent fakes, but with
a little practice it's easy to tell whether Zilch or Inform compiled a
file from the style of code generated.
</li>
</ol>
<hr>
<p>
<a href="index.html">Contents</a> /
<a href="preface.html">Preface</a> /
<a href="overview.html">Overview</a>
</p>
<p>Section
<a href="sect01.html">1</a> / <a href="sect02.html">2</a> /
<a href="sect03.html">3</a> / <a href="sect04.html">4</a> /
<a href="sect05.html">5</a> / <a href="sect06.html">6</a> /
<a href="sect07.html">7</a> / <a href="sect08.html">8</a> /
<a href="sect09.html">9</a> / <a href="sect10.html">10</a> /
<a href="sect11.html">11</a> / <a href="sect12.html">12</a> /
<a href="sect13.html">13</a> / <a href="sect14.html">14</a> /
<a href="sect15.html">15</a> / <a href="sect16.html">16</a>
</p>
<p>Appendix
<a href="appa.html">A</a> / <a href="appb.html">B</a> /
<a href="appc.html">C</a> / <a href="appd.html">D</a> /
<a href="appe.html">E</a> / <a href="appf.html">F</a>
</p>
<hr>
</body>
</html>