mapthing { recordnum = 1; }
mapthing
{
recordnum = 1;
}
mapthing
{
recordnum =
1 ;;;;;;
}
Obviously, you are encouraged to use a clean and consistent format, even though
it is not required.
# Single line comment
// Another single line comment
/*
This is a multiline comment
*/
somefield = "This string is split \
across two lines"
The "\" character, when followed immediately by a line break, signifies that line
continuation should be triggered. Whitespace before the line continuation will be
included in the string, but any spaces or tabs at the beginning of the next line will
NOT be included (this is the same as line continuation in BEX and EDF files). This
allows the following continued parts of the string to be arbitrarily indented for
purposes of beautification. A string can be split across any number of lines in
this fashion.
# this is a normal, decimal number (base 10)
recordnum = 16
...
# this is an octal number (base 8)
recordnum = 020
...
# this is a hexadecimal number (base 16)
recordnum = 0x10
Floating-point numbers must have a decimal point in them, as in "20.0". Floating-point
numbers are always base 10.
Embedding and Associating ExtraData
ExtraData is embedded directly as a text script into a lump of any name. This can be done with
any number of wad file management tools, including WinTex (though WinTex has some bugs which
make the process more complicated).
An ExtraData script is associated with a map via use of the MapInfo variable extradata. A map can only have one ExtraData script, but it is possible for multiple maps to share the same script.
Example of ExtraData specification via MapInfo:
[level info] extradata = EDLUMP01ExtraData (as well as all other MapInfo variables) can be specified in either global or level-header MapInfo scripts.
Mapthings
Mapthings define monsters, lamps, control points, items, etc -- anything that is spawned on
the map at level start.
Each field in the mapthing definition, with the exception of the recordnum field, is optional. If a field is not provided, it takes on the default value indicated below the syntax information. Fields may also be provided in any order.
Note that the order of mapthing definitions in ExtraData is not important. The recordnum field serves to identify mapthing records.
Creating ExtraData Control Objects
Mapthing records in ExtraData are only associated with a special control object that must be
placed on the map in the usual manner in your editor of choice.
The ExtraData control object has a doomednum of 5004. Each control object specifies its corresponding ExtraData mapthing record number as an integer value in its mapthing options field. If your editor does not allow entering arbitrary values into the options field of mapthings, you will need to use the BOOM command-line editor, CLED. As of the initial writing time of this document, both DETH and Doom Builder support entering arbitrary integer values for the options field. Check your editor's documentation or user interface to verify if it supports this.
The x, y, and angle fields of the ExtraData control object are passed on to the thing which will be spawned at the control point's location, so those fields of the control object should be set normally. The true type and options fields of the thing to be spawned, along with any extended fields, are specified in the ExtraData record which the control thing references.
Any number of ExtraData control objects can reference the same ExtraData record. In the event that a control object references a non-existant ExtraData record, the ExtraData script for a level is missing, or the thing type referenced by an ExtraData record isn't valid, an Unknown thing will be spawned at the control point's location. See the EDF Documentation for information on the required Unknown thingtype definition. Note that you cannot spawn ExtraData control objects using ExtraData. Attempting this will also result in an Unknown thing.
Mapthing Syntax and Fields
The syntax of the ExtraData mapthing record is as follows. Remember that all fields except
the recordnum field are optional and can be specified in any order.
mapthing
{
recordnum = <unique number>
# These fields are normal mapthing fields
type = <doomednum> OR <EDF thingtype mnemonic>
options = <options flag list>
# These fields are ExtraData extensions
tid = <number>
args = { <special field>, ... }
}
Explanation of fields:
mapthing { type = 3001 } // This record specifies an Imp via its doomednum
mapthing { type = thing:DoomImp } // This record specifies an Imp by its EDF mnemonic
Flag name Decimal Hex Meaning
------------------------------------------------------------------------------
EASY 1 0x0001 Thing appears in easy difficulties
NORMAL 2 0x0002 Thing appears in "Hurt Me Plenty"
HARD 4 0x0004 Thing appears in Ultra-Violence and Nightmare
AMBUSH 8 0x0008 Thing is "deaf", will not wake up via sound
NOTSINGLE 16 0x0010 Thing doesn't appear in single-player mode
NOTDM 32 0x0020 Thing doesn't appear in deathmatch
NOTCOOP 64 0x0040 Thing doesn't appear in cooperative multiplayer
FRIEND 128 0x0080 Thing uses MBF friendly logic
DORMANT 512 0x0200 Thing is dormant at map startup (script feature)
------------------------------------------------------------------------------
The mapthing options value 256 (0x0100) is reserved. If this bit is set, all BOOM, MBF,
and Eternity extended mapthing bits will be cleared. This is to guard against editors like
Hellmaker which set all bits they do not understand, instead of leaving them zero.
# This is the only syntax that does not require quotations.
mapthing { options = EASY|NORMAL|HARD }
# All of these syntaxes must be quoted, because unquoted strings in
# ExtraData cannot contain spaces, commas, or plus signs.
mapthing { options = "EASY NORMAL HARD" }
mapthing { options = "EASY | NORMAL | HARD" }
mapthing { options = "EASY+NORMAL+HARD" }
mapthing { options = "EASY + NORMAL + HARD" }
mapthing { options = "EASY,NORMAL,HARD" }
mapthing { options = "EASY, NORMAL, HARD" }
mapthing { args = { 0, 1, 2, 3, 4 } }