1
! ==============================================================================
2
! PARSER: Front end to parser.
4
! Supplied for use with Inform 6 -- Release 6/11 -- Serial number 040227
6
! Copyright Graham Nelson 1993-2004 but freely usable (see manuals)
8
! In your game file, Include three library files in this order:
12
! ==============================================================================
16
! ------------------------------------------------------------------------------
18
Constant LibSerial "040227";
19
Constant LibRelease "6/11";
20
Constant LIBRARY_VERSION 611;
21
Constant Grammar__Version 2;
23
Default COMMENT_CHARACTER '*';
29
#Ifndef WORDSIZE; ! compiling with Z-code only compiler
30
Constant TARGET_ZCODE;
34
#Ifdef TARGET_ZCODE; ! offsets into Z-machine header
36
Constant HDR_ZCODEVERSION $00; ! byte
37
Constant HDR_TERPFLAGS $01; ! byte
38
Constant HDR_GAMERELEASE $02; ! word
39
Constant HDR_HIGHMEMORY $04; ! word
40
Constant HDR_INITIALPC $06; ! word
41
Constant HDR_DICTIONARY $08; ! word
42
Constant HDR_OBJECTS $0A; ! word
43
Constant HDR_GLOBALS $0C; ! word
44
Constant HDR_STATICMEMORY $0E; ! word
45
Constant HDR_GAMEFLAGS $10; ! word
46
Constant HDR_GAMESERIAL $12; ! six ASCII characters
47
Constant HDR_ABBREVIATIONS $18; ! word
48
Constant HDR_FILELENGTH $1A; ! word
49
Constant HDR_CHECKSUM $1C; ! word
50
Constant HDR_TERPNUMBER $1E; ! byte
51
Constant HDR_TERPVERSION $1F; ! byte
52
Constant HDR_SCREENHLINES $20; ! byte
53
Constant HDR_SCREENWCHARS $21; ! byte
54
Constant HDR_SCREENWUNITS $22; ! word
55
Constant HDR_SCREENHUNITS $24; ! word
56
Constant HDR_FONTWUNITS $26; ! byte
57
Constant HDR_FONTHUNITS $27; ! byte
58
Constant HDR_ROUTINEOFFSET $28; ! word
59
Constant HDR_STRINGOFFSET $2A; ! word
60
Constant HDR_BGCOLOUR $2C; ! byte
61
Constant HDR_FGCOLOUR $2D; ! byte
62
Constant HDR_TERMCHARS $2E; ! word
63
Constant HDR_PIXELSTO3 $30; ! word
64
Constant HDR_TERPSTANDARD $32; ! two bytes
65
Constant HDR_ALPHABET $34; ! word
66
Constant HDR_EXTENSION $36; ! word
67
Constant HDR_UNUSED $38; ! two words
68
Constant HDR_INFORMVERSION $3C; ! four ASCII characters
70
#Ifnot; ! TARGET_GLULX ! offsets into Glulx header and start of ROM
72
Constant HDR_MAGICNUMBER $00; ! long word
73
Constant HDR_GLULXVERSION $04; ! long word
74
Constant HDR_RAMSTART $08; ! long word
75
Constant HDR_EXTSTART $0C; ! long word
76
Constant HDR_ENDMEM $10; ! long word
77
Constant HDR_STACKSIZE $14; ! long word
78
Constant HDR_STARTFUNC $18; ! long word
79
Constant HDR_DECODINGTBL $1C; ! long word
80
Constant HDR_CHECKSUM $20; ! long word
81
Constant ROM_INFO $24; ! four ASCII characters
82
Constant ROM_MEMORYLAYOUT $28; ! long word
83
Constant ROM_INFORMVERSION $2C; ! four ASCII characters
84
Constant ROM_COMPVERSION $30; ! four ASCII characters
85
Constant ROM_GAMERELEASE $34; ! short word
86
Constant ROM_GAMESERIAL $36; ! six ASCII characters
91
Message fatalerror "*** Library 6/11 needs Inform v6.10 or later to work ***";
101
Fake_Action PluralFound;
102
Fake_Action ListMiscellany;
103
Fake_Action Miscellany;
105
Fake_Action NotUnderstood;
112
! ------------------------------------------------------------------------------
114
[ Main; InformLibrary.play(); ];
116
! ------------------------------------------------------------------------------
122
#Endif; ! USE_MODULES
124
! ==============================================================================
126
Constant LIBRARY_PARSER; ! for dependency checking
128
! ==============================================================================