Editing ExtraData
From Eternity Wiki
Jump to navigationJump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
ExtraData is a new data specification language for the [[Eternity Engine]] that allows arbitrary extension of mapthings, lines, and sectors with any number of new fields, with data provided in more or less any format. The use of a textual input language forever removes any future problems caused by binary format limitations. The ExtraData parser is based on the libConfuse configuration file parser library by Martin Hedenfalk, which is also used by GFS and EDF. | |||
ExtraData | Each section in this document deals with one of the ExtraData constructs, as well as how to embed ExtraData in a WAD and how to associate it with a given map. | ||
ExtraData will continue to be supported in future versions of Eternity, even though it will soon be superceded by support for the [[Universal Doom Map Format]]. | |||
=General Syntax= | =General Syntax= | ||
''See [[EDF#Syntax|EDF Syntax]], as it is the same.'' | ''See [[EDF#Syntax|EDF Syntax]], as it is the same.'' | ||
Line 50: | Line 49: | ||
// These fields are ExtraData extensions | // These fields are ExtraData extensions | ||
tid <number> | tid <number> | ||
args { <special field>, ... } | args { <special field>, ... } | ||
height <number> | height <number> | ||
Line 64: | Line 62: | ||
This field can also accept EDF thingtype mnemonics. EDF thingtype mnemonics must be prefixed with ''thing:'' -- this allows the parser to know it is dealing with a string instead of a number. EDF thingtypes must have a unique doomednum to be specified in an ExtraData mapthing record. If the specified EDF thingtype doesn't exist or has a doomednum of -1, an Unknown object will be spawned instead. | This field can also accept EDF thingtype mnemonics. EDF thingtype mnemonics must be prefixed with ''thing:'' -- this allows the parser to know it is dealing with a string instead of a number. EDF thingtypes must have a unique doomednum to be specified in an ExtraData mapthing record. If the specified EDF thingtype doesn't exist or has a doomednum of -1, an Unknown object will be spawned instead. | ||
Example: | Example: | ||
Line 71: | Line 67: | ||
mapthing { type DoomImp } // This record specifies an Imp by its EDF mnemonic | mapthing { type DoomImp } // This record specifies an Imp by its EDF mnemonic | ||
====options==== | ====options==== | ||
Default: No flags are set by default. | Default: No flags are set by default. | ||
Line 91: | Line 87: | ||
FRIEND Thing uses MBF friendly logic | FRIEND Thing uses MBF friendly logic | ||
DORMANT Thing is dormant at map startup (script feature) | DORMANT Thing is dormant at map startup (script feature) | ||
------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ||
Line 114: | Line 109: | ||
Default: 0 | Default: 0 | ||
The TID, or "Thing ID", is a tag for mapthings which is used for identification in [[ | The TID, or "Thing ID", is a tag for mapthings which is used for identification in [[Small]] scripts. TID values must be positive numbers between 1 and 65535. The TID value zero means no TID. Negative TID values are reserved and are used to indicate special things within the engine. TIDs are not required to be unique, and most Small functions that accept TIDs will perform an action on all mapthings which bear the same TID. Things spawned within Small scripts can also be given TIDs. | ||
====args==== | ====args==== | ||
Line 166: | Line 156: | ||
extflags <extended line flags list> | extflags <extended line flags list> | ||
args { <special field>, ... } | args { <special field>, ... } | ||
alpha <number> | alpha <number> | ||
} | } | ||
Line 195: | Line 184: | ||
Flag name Meaning | Flag name Meaning | ||
--------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | ||
CROSS | CROSS Linedef can be activated by being crossed. | ||
USE | USE Linedef can be activated by being used. | ||
IMPACT | IMPACT Linedef can be activated by being shot. | ||
PUSH | PUSH Linedef can be activated by being pushed. | ||
PLAYER | PLAYER Linedef can be activated by players. | ||
MONSTER | MONSTER Linedef can be activated by objects with SPACMONSTER flag. | ||
MISSILE | MISSILE Linedef can be activated by objects with SPACMISSILE flag. | ||
REPEAT Linedef action is repeatable. | |||
REPEAT | 1SONLY Linedef can only be activated from first side. | ||
1SONLY | ADDITIVE Linedef's midtexture is drawn with additive blending. | ||
ADDITIVE | BLOCKALL Linedef will block everything that can be clipped. | ||
BLOCKALL | |||
--------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | ||
Notes: IMPACT is currently only implemented for bullet weapons. | Notes: IMPACT is currently only implemented for bullet weapons. The ability to use IMPACT with MISSILE will be added in the near future. The PUSH style of activation is not implemented at all yet, so this flag currently does nothing. | ||
Example flags fields -- All of these are equivalent: | Example flags fields -- All of these are equivalent: | ||
Line 239: | Line 221: | ||
Example args list: | Example args list: | ||
linedef { args { 0, 1, 2, 3, 4 } } | linedef { args { 0, 1, 2, 3, 4 } } | ||
====alpha==== | ====alpha==== | ||
: | :"Default: Alpha defaults to 1.0." | ||
The alpha field takes a value from 0.0 to 1.0 to set the opacity at which this linedef's midtexture is drawn. When combined with the ADDITIVE extflag, this can be used for additive-blended translucency as well. | The alpha field takes a value from 0.0 to 1.0 to set the opacity at which this linedef's midtexture is drawn. When combined with the ADDITIVE extflag, this can be used for additive-blended translucency as well. | ||
Line 286: | Line 264: | ||
flooroffsetx <float> | flooroffsetx <float> | ||
flooroffsety <float> | flooroffsety <float> | ||
ceilingterrain <terrain name> | ceilingterrain <terrain name> | ||
ceilingangle <float> | ceilingangle <float> | ||
ceilingoffsetx <float> | ceilingoffsetx <float> | ||
ceilingoffsety <float> | ceilingoffsety <float> | ||
colormaptop <lump name> | colormaptop <lump name> | ||
colormapmid <lump name> | colormapmid <lump name> | ||
Line 301: | Line 275: | ||
overlayalpha.floor <percentage or value from 0 to 255> | overlayalpha.floor <percentage or value from 0 to 255> | ||
overlayalpha.ceiling <percentage or value from 0 to 255> | overlayalpha.ceiling <percentage or value from 0 to 255> | ||
} | } | ||
===Explanation of fields: === | ===Explanation of fields: === | ||
Line 322: | Line 294: | ||
KILLSOUND Objects in sector cannot make sounds. | KILLSOUND Objects in sector cannot make sounds. | ||
KILLMOVESOUND Sector makes no movement sounds, even if it has a special sound sequence | KILLMOVESOUND Sector makes no movement sounds, even if it has a special sound sequence | ||
--------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | ||
Line 407: | Line 376: | ||
Specifies the x and y offsets of the floor flat, relative to the normal floor grid, in floating point units. | Specifies the x and y offsets of the floor flat, relative to the normal floor grid, in floating point units. | ||
====ceilingterrain==== | ====ceilingterrain==== | ||
Line 423: | Line 387: | ||
Specifies the angle of the ceiling flat in floating-point degrees from 0 to 359. Note that for compatibility with ZDoom, the angle specified advances in a '''clockwise''' fashion, contrary to most other angles in the DOOM engine. | Specifies the angle of the ceiling flat in floating-point degrees from 0 to 359. Note that for compatibility with ZDoom, the angle specified advances in a '''clockwise''' fashion, contrary to most other angles in the DOOM engine. | ||
==== | ====flooroffsetx/flooroffsety==== | ||
:''Default: 0'' | :''Default: 0'' | ||
Specifies the x and y offsets of the ceiling flat, relative to the normal ceiling grid, in floating point units. | Specifies the x and y offsets of the ceiling flat, relative to the normal ceiling grid, in floating point units. | ||
====colormaptop==== | ====colormaptop==== | ||
Line 448: | Line 407: | ||
Specifies the colormap lump to use when a player's viewpoint is below the fake floor of a BOOM 242 "deep water" effect applying to this sector. If left to default, the global colormap from MapInfo will be used as normal, unless one is specified by the 242 effect. | Specifies the colormap lump to use when a player's viewpoint is below the fake floor of a BOOM 242 "deep water" effect applying to this sector. If left to default, the global colormap from MapInfo will be used as normal, unless one is specified by the 242 effect. | ||
====portalflags | ====portalflags==== | ||
:''Default: No flags are set by default.'' | :''Default: No flags are set by default.'' | ||
Line 457: | Line 416: | ||
Flag name Meaning | Flag name Meaning | ||
--------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | ||
DISABLED | DISABLED Portal is completely disabled | ||
NORENDER | NORENDER Portal will not be rendered, but may still be interactive | ||
NOPASS | NOPASS Objects cannot pass through the portal even if it is a linked portal | ||
BLOCKSOUND | BLOCKSOUND Sound will not traverse through a linked portal | ||
OVERLAY | OVERLAY The portal will render the sector's flat as a blended overlay | ||
ADDITIVE | ADDITIVE If OVERLAY is also specified, the overlay will use additive blending | ||
USEGLOBALTEX | USEGLOBALTEX Reserved for future per-portal texture specification | ||
--------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | ||
====overlayalpha | ====overlayalpha==== | ||
:''Default'': 100% | :''Default'': 100% | ||
These two fields (overlayalpha.floor and overlayalpha.ceiling) specify the opacity of the corresponding portal overlay, if any exists. You can specify either a percentage value from 0% to 100%, or a plain integer number from 0 to 255. 100%/255 are completely solid, while 0% is invisible. | These two fields (overlayalpha.floor and overlayalpha.ceiling) specify the opacity of the corresponding portal overlay, if any exists. You can specify either a percentage value from 0% to 100%, or a plain integer number from 0 to 255. 100%/255 are completely solid, while 0% is invisible. | ||