-
Notifications
You must be signed in to change notification settings - Fork 0
/
export.doc
93 lines (65 loc) · 3.31 KB
/
export.doc
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
This document describes the level export format of Free Hero Mesh.
You can use this format for the following purposes:
* To copy a level in Free Hero Mesh, within the same puzzle set or from
one puzzle set to another one.
* To export a level, to be parsed by an external program.
* To produce by an external program and then import into Free Hero Mesh.
* To edit it in a text editor.
(In the first case, when duplicating the level within the same puzzle set,
you can also just copy the .LVL lump. However, that will not work if you
are copying between puzzle sets.)
Each line is one record, and is terminated by a line feed. Everything in
this file is case-sensitive.
=== Types of records ===
;comment
A comment. A blank line is also a comment.
@title
Specify the title of the level. This may contain escapes. A line break
must be escaped, and a backslash must be escaped, although a quotation
mark does not need to be escaped.
C code
The level code number, from 0 to 65535.
D width height
The play field dimensions. The width and height must be 1 to 64. This
line must come before any objects are listed, and is mandatory.
F $class
This command never occurs in levels exported from Free Hero Mesh,
although it can optionally occur in imported levels. This command fills
the entire playfield with the specified class; the image number and
other parameters are always zero.
V version
This command never occurs in levels exported from Free Hero Mesh,
although it can optionally occur in imported levels. If it is specified,
then it sets the level version number.
W
After all objects in the normal world, use this command to start the
objects in the bizarro world; you then need another W at the end.
x y $class image misc1 misc2 misc3 dir
Specify an object. Objects are listed starting from the top left corner,
going right, and within each cell the objects are listed from bottom to
top. Coordinates are one-based. The image is a number (0 for the first
image), misc1 to misc3 are misc values (see below), and dir is also a
number (0 for east, up to 7 for southeast). When the data is being
imported, it will accept objects listed in any order, but when being
exported from Free Hero Mesh, they are ordered as described above.
%string
A level string. The level strings are numbered in order, starting from
string 0. The format is like that of the title.
'key number
Specify the key name (same as the "input constants" described in
class.doc), and optionally the repeat count. This enters it into the
solution; if at least one command like this is present then it will
overwrite the existing solution when this level is saved. (Note: This
does not automatically verify the solution; it only records it.)
(Currently, this line is implemented only for import, and not for
export. Later an option might be added to do this on export, too.)
=
Delimiter between levels; only allowed in batch import mode.
=== Misc values ===
A number is written in decimal, and must be 0 to 65535.
A class name has $ at first.
A message name will start with # if it is a user-defined message, or will
have no prefix if it is a standard message.
A reference to a level string starts with % and is then the number.
None of the misc values are written with spaces inside the value, although
there are spaces around the value.