The wall data files contain information about a particular wall. You will need one wall data file for each wall in the game, and each wall data file must be indexed in your walllist.txt data file. Wall data files obey the same rules of syntax as all other text data files, ignoring white space and lines beginning with a '#' comment character.
Wall data files include several pieces of data describing the nature of the wall at the beginning, and then the second half of the wall file contains a list of all graphic files (or "brushes") and their coordinates used to draw each view of the wall. The rows of data in the wall data file are:
- WALLNAME: "name" (The keyword "WALLNAME:" must be spelled with capital letters and the colon, and the name of the wall, appearing in quotation marks, will be displayed inside the mapeditor program to make it easier for you to find and identify the wall you want to use.)
- A row containing a list of data elements representing:
- Two story wall flag (0 = wall is not a two-story building, 1 = wall is a two-story building) It is necessary which walls are taller than normal so that occlusion culling works properly.
- Visible wall flag (0 = wall is drawn, 1 = wall is not drawn)
- Occulding wall flag (0 = it is possible to see through parts of the wall to objects behind it. 1 = the wall takes up the entire space space available and no part is masked or can be seen through) This flag is used as a cue to help occlusion culling.
- Default Blocking wall flag (0 = you can walk through the wall. 1 = you cannot walk through the wall). Note that this is simply a default value. Inside the mapeditor, you can manually change the blocking bit for any wall.
- Symmetric flag (0 = Wall looks different on one particular side. 1 = wall looks same from all sides). Walls such as trees or treasure chests are symmetric, but walls such as dungeon walls with a torch on the front are not. In the mapeditor, each time you place a non-symmetric wall, you must manually set which of the four sides of the wall is the unique one. The other three sides will simply display the "base" wall (see below).
- Base wall (0 = no base wall, 1-7 = use base wall). If a base wall 1-7 is given, that wall is drawn before the current one. This is useful for drawing complex walls that are very similar. Put undecorated versions of complex walls at wall index number 1 through 7. Then you can re-use those generic versions of the walls for later walls by referencing them as a base wall. When those later walls are drawn, first the base, generic-looking wall is drawn, then the decoration brushes listed in the current wall are drawn on top.
- Default building flag (0 = wall is not a building, 1 = wall is a building) This flag is only used to determine whether your party will face the building when exiting it, or face away when exiting (according to the user preference). This default flag can be overriden in the mapeditor.
- Default Empty flag (0 = the wall is not a generic empty town building. 1 = the wall is a generic empty town building). Note that this default flag can be overridden for any particular instance of the wall in the mapeditor. Using walls with the building flag set means you can walk into the building and sleep at night.
- Mapeditor character (any printable character may be used) This is the character used to display the wall inside the mapeditor.
- Maptiles (four numbers must be specified in the range of 0..maxBrushID) These four numbers represent the indicies of the maptile (in your brush list) to the graphic for the small overhead map square for the wall facing north, south, east, and west, respectively. If your wall is symmetric, all four overhead map tile indicies should be the same. There is no need to specify the four large overhead map tile indicies here because they are referenced automatically using the maptileindex.txt data.
After the row of wall description data is given, as per above, you must specify a set of 10 wall views. All ten wall views must be specified, according to the following syntax, in order, without any ommissions. The ordering of the wall view descriptions, along with their top-left coordinates, are:
|0||Front 0||0, 0||160, 160||Standing on top of the wall|
|1||Front 1||20, 20||120, 120||Standing immediately in front of it|
|2||Front 2||40, 40||80, 80||Standing one step away|
|3||Front 3||52, 52||56, 56||Standing two steps away|
|4||Front 4||60, 60||40, 40||Standing three steps away|
|5||Left 0||0, 0||20, 160||Standing next to the wall, with your left side facing it|
|6||Left 1||20, 20||20, 120||Standing one square away, left side facing it|
|7||Left 2||40, 40||12, 80||Standing two squares away, left side facing it|
|8||Left 3||52, 52||8, 56||Standing three squares away, left side facing it|
|9||Farleft||0, 52||20, 56||Standing three squares away, two squares to the left, left side facing wall|
The format for each of the ten wall view descriptions is as follows:
- Number of brushes in the wall view (0..255). Note that there can be a maximum of 255 brushes for an entire wall, so if you use too many brushes to construct one view, you might not have enough for other views.
- For each brush, specify a row describing how to draw that brush with the following data:
- Brush number (0..maxBrushID) Specify the index for the graphic file for the desired brush
- x coordinate (0..max wall width for current view). The x coordinate is relative to the top-left corner where the wall view is drawn, not the top-left corner of the screen. To find out the true coordinate of the brush, add your given x coordinate to the top-left of the wall view given above.
- y coordinate (0..max wall height for current view). The x coordinate is relative to the top-left corner where the wall view is drawn, not the top-left corner of the screen. To find out the true coordinate of the brush, add your given x coordinate to the top-left of the wall view given above.
- start x coordinate (0..brush width) If you only wish to draw a section from the brush, you can specify the coordinates within the brush from which to start drawing. Note that the starting x coordinate must be a multiple of 4.
- start y coordinate (0..brush height) If you only wish to draw a section from the brush, you can specify the coordinates within the brush from which to start drawing. Note that the starting x coordinate must be a multiple of 4.
- end x coordinate (0..255). If you wish to draw to the end of the brush, use 255. But if you wish to stop drawing before the end of the brush and only draw a section from the brush, you can specify the ending coordinate (must be a multiple of 4.
- end y coordinate (0..255). If you wish to draw to the end of the brush, use 255. But if you wish to stop drawing before the end of the brush and only draw a section from the brush, you can specify the ending coordinate (must be a multiple of 4.
- Horizontal flip flag (0 = do not flip the brush, 1 = draw the brush flipped)
- Vertically flip flag (0 = do not flip the brush, 1 = draw the brush flipped)
# Wall #28: Pentagram on floor with skeleton 'o'
WALLNAME: "Pentagram on floor with skeleton on it"
# twostory Visible Occludes Blocks Symmetric Base building empty Char maptiles
0 1 0 0 1 0 0 0 o 330 330 330 330
# Front 0 View
# Front 1 View
# BrushNum x y sx sy ex ey H V
161 32 103 0 0 255 255 0 0
162 48 103 0 0 255 255 0 0
162 60 103 0 0 255 255 1 0
161 72 103 0 0 255 255 1 0
163 40 96 0 0 255 255 0 0
# Front 2 View
# BrushNum x y sx sy ex ey H V
148 20 71 0 0 255 255 0 0
148 20 71 0 0 255 255 1 0
164 28 67 0 0 255 255 0 0
# Front 3 View
# BrushNum x y sx sy ex ey H V
6 12 51 0 0 255 255 0 0
6 28 51 0 0 255 255 1 0
165 20 49 0 0 255 255 0 0
# Front 4 View
# Left 0 View
# Left 1 View
# Left 2 View
# Left 3 View
# FarLeft View