Editing
EDF basics
(section)
From Eternity Wiki
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Implementation== ===Loading EDF=== By default, Eternity loads the EDF file from the relative path: ''base\root.edf''. The root file can be substituted as follows, either from an external file or a WAD lump: * To load an EDF root from a WAD file, the name of the root EDF lump must be "EDFROOT". * To include an EDF file from the command line, use the -edf parameter. For example: ''eternity -edf c:\blah\root.edf'' * A [[GFS]] file can specify the root EDF file with the '''edffile''' keyword. Only one EDF file can be specified in a GFS. If -edf is used when a GFS is loaded, the command-line parameter will take precedence. See the GFS documentation for further information. Unless the intention is to redefine the entire game structure, the overriding root EDF file must contain a command at the top to include the ''base\root.edf'' file, by using this function: ''stdinclude("root.edf")''. Note that it is possible to load several wads containing EDFROOT; they will be processed additively. NOTE: EDF data is always loaded before any [[Dehacked]] lumps. ===Including files=== Use of include files is critical for several purposes. First, it's unorganized and difficult to maintain EDF files when everything is put haphazardly into one file. To include a file or wad lump normally, with a path relative to the current file doing the inclusion, use the include function, like in these examples: # include examples include("myfile.edf") include("../prevdir.edf"); # remember, semicolons are purely optional This example would include "myfile.edf" from the same directory that the current file is in, and "prevdir.edf" from the parent directory. It is important to note that this function can only include files when called from within a file, and it can only include WAD lumps when called from within a WAD lump. This restriction is necessary due to how the complete path of the included file must be formed. In order to remain compatible with future versions of Eternity, and to greatly reduce EDF file sizes, include the standard, default EDF files into your own. To include the files from Eternity's ''base'' directory, use the '''stdinclude''' function: stdinclude("root.edf") Note: to ensure backward and forward compatibility, do not include other EDF files from the ''base'' directory than ''root.edf''. Include statements may only be located at the topmost level of an EDF file, and not inside any section. The '''userinclude''' function allows the optional inclusion of a file from Eternity's ''base'' folder. This function is identical to '''stdinclude''', except that it will test to see if the file exists beforehand, and if it does not, no error will occur. This function is NOT for use by EDF editors in projects. This function is intended for end-user modification of EDF settings, including but not limited to the custom user menu. Example: userinclude("user.edf") This example can be found in Eternity's root.edf, where it exists to include the optional user-defined "user.edf" file. You should never attempt to overwrite the user.edf file with one from your own project, as this is outside the scope of its purpose and will be offensive to the end user. ===Including lumps=== This '''lumpinclude''' function includes a wad lump when called from either a file or a lump. The lump named must exist, or an error will occur. The name must also be no longer than eight characters. Case of the lump name will be ignored as usual. Example: lumpinclude("MYEDFLMP") Note: including a lump or file several times will not cause duplicate loading of data. ===Including BEX files{{deprecated}}=== It is possible to include BEX files by using: bexinclude("file.bex") but it is recommended to use the DEHACKED lump or GFS files rather than EDF. ===Base EDF files=== This section explains the contents of each of the standard default EDF modules. Note that some are game-dependent and are in consequence included in their respective folders, as well as the base folder for the common features. * cast.edf -- contains '''castinfo''' (Doom 2 cast call) definitions * fonts.edf -- contains '''font''' definitions -- game dependent * frames.edf -- contains '''frame''' definitions -- game dependent * misc.edf -- contains '''boss_spawner_types''' and some Heretic-specific '''string''' blocks * player.edf -- contains '''skin''' and '''playerclass''' definitions * root.edf -- includes all other modules * sounds.edf -- contains '''sound''' and '''soundsequence''' definitions -- game dependent * sprites.edf -- contains '''spritenames''' and '''pickupitem''' definitions * terrain.edf -- contains '''splash''', '''terrain''', '''floor''' definitions * things.edf -- contains '''thingtype''' and '''damagetype''' definitions -- game dependent * user.edf -- optional user-defined EDF file which may contain any definitions ===Default fallbacks=== As of 3.39.20, default fallback no longer exists. ===Lumps besides EDFROOT that are automatically loaded=== Eternity can load other EDF lumps, besides EDFROOT. Previously, they were dedicated to specific blocks, but now can have any purpose. Do not explicitly include them from EDFROOT. *EFONTS *EMENUS *EREVERBS *ESNDINFO *ESNDSEQ *ESTRINGS *ETERRAIN *EWEAPONS ===Reserved identifiers=== This section describes classes of identifiers (such as thing, frame, and sound mnemonics) which are considered reserved by the Eternity Engine. You should avoid using any identifier in the following classes for objects which you define yourself. Failure to do so could result in incompatibility of your project with future versions of the Eternity Engine due to conflicts with newly added game engine features. * All identifiers beginning with _ (underscore) * All identifiers beginning with EE or ee (this prefix means "Eternity Engine" and is therefore reserved for use by the source port's authors only). * All identifiers containing ANY non-alphanumeric character excepting non-leading underscores (ex: $ is reserved). For maximum safety, it is recommended that you develop a consistent and unique naming scheme for objects you create yourself. This has the positive side effect of improving the ability of your EDF patches to combine with those of others.
Summary:
Please note that all contributions to Eternity Wiki are considered to be released under the GNU Free Documentation License 1.2 (see
Eternity Wiki:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Page actions
Page
Discussion
Read
Edit
History
Page actions
Page
Discussion
More
Tools
Personal tools
Not logged in
Talk
Contributions
Log in
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Search
Tools
What links here
Related changes
Special pages
Page information