EE 3.40.46 "Bifrost" - New Feature Documentation ------------------------------------------------------------------------------- ------------------------------------------------------------------------------- EDF Item Effects and Inventory ------------------------------------------------------------------------------- Define what happens when an item is picked up (and eventually, used or dropped from the inventory - this is not complete yet). There are many different types of item effect definitions: // An artifact is an item which, when collected, goes into the player's // inventory. artifact { amount // amount gained with one pickup maxamount // max amount that can be carried in inventory interhubamount // max amount carryable between levels in different hubs; // -1 if this field should not apply at all sortorder // key used for sorting the player's inventory icon // name of icon graphic for invbar (currently unused) usesound // sound made when item is used (currently unused) useeffect // name of item effect to use for activation (unused) [+-]undroppable // if +, cannot be dropped from inventory [+-]invbar // if +, appears in invbar; otherwise, invisible [+-]keepdepleted // if +, will remain in inventory with amount of zero [+-]fullamountonly // if +, cannot pickup unless full amount is needed // artifacttype determines what sort of artifact this is. artifacttype // "Normal", "Ammo", "Key", "Puzzle", "Power", "Weapon", // or "Quest" // The following fields apply only to certain artifact types. They have no // effect if specified on other types. // Ammo ammo.backpackamount // amount of this ammo type given by a Backpack ammo.backpackmaxamount // max amount after collecting a Backpack } // A health effect gives the player health in one of many possible ways. healtheffect { amount // amount of health to give maxamount // max amount this item can health to; if player has greater // health, the item cannot be picked up at all. lowmessage // alternate message to give instead of pickupfx message when // health is < amount; if starts with $, is a BEX mnemonic. [+-]alwayspickup // if +, item is picked up even when unneeded (ie Health Bonus) [+-]sethealth // if +, item SETS health rather than adding to it (ie Megasphere) } // An armor effect defines the properties of player armor armoreffect { saveamount // amount of armor given savefactor // numerator of fraction determining save percentage savedivisor // denominator of fraction determining save percentage maxsaveamount // max amount his item can give; if player has greater // armor, the item cannot be picked up at all [+-]alwayspickup // item is picked up even when unneeded (ie Armor Bonus) [+-]bonus // if +, is a bonus (adds to current armor type without // changing the protective qualities) } // Ammo givers give an Ammo type artifact to the player. ammoeffect { ammo // Name of an Ammo-type artifact definition amount // Amount to give for an ordinary pickup dropamount // Amount to give if dropped by an enemy [+-]ignoreskill // if +, does not double on skills that give double ammo } ------------------------------------------------------------------------------- EDF Lockdefs ------------------------------------------------------------------------------- Define what happens when locked lines are activated. For Doom and Heretic map formats, the lockdef IDs used by certain linedefs are hardcoded. Once ACS_LockedExecute is implemented (not done yet), it will be possible to use it through ExtraData for those map formats, as well as in Hexen-format maps. A lockdef defining the same unique ID number as a previous definition will overwrite that previous definition. A lockdef which specifies neither "require" keys nor "any" keys can be activated by possession of any one Key type artifact, period. lockdef { require // Name of a Key artifact type the player must have in his/her // inventory for the lock to activate. Any number of keys can // be required by specifying this field more than once. // An "any" section, of which there can be any number, defines a set of keys // out of which the player must possess *at least one* in each "any" section. // There can be any number of these sections defined. any { keys [, ]* // list of one or more Key artifact types } message // Message to give if manual lock activation fails. If // this string starts with a $, it is a BEX string // mnemonic. remotemessage // Message to give if remote lock activation fails. If // this string starts with a $, it is a BEX string // mnemonic. lockedsound // Name of EDF sound to play when lock activation fails. // If unspecified, the player's skin "oof" sound is // used as normal. // Mapcolor may have one of three possible values (all are treated as strings // and then interpreted according to their contents): // * If the value begins with #, it will be treated as a 6-digit hexadecimal // number specifying a 24-bit RGB color value. This value will be matched to // the closest index in the PLAYPAL. That color will be used to display any // linedefs in the automap using this lockdef. // * If the value begins with $, it will be treated as the name of a console // variable which holds a palette index (0-255) to use. Only integer cvars // with a range of 0-255 can be specified here. // * Otherwise, the value is treated as an integer which should be in the range // from 0 to 255, and is used as a palette index for the color to use. mapcolor } ------------------------------------------------------------------------------- New Thingtype Features ------------------------------------------------------------------------------- thingtype [: [, [, ]]] { // dropitem defines a Doom- or Heretic-style drop item; any number of // dropitems can be defined. All are dropped when an enemy dies, subject // to possible randomization. dropitem [, [, [, ]]] // Explanation of dropitem multivalue properties: // : Name of EDF thingtype to spawn // : If specified, chance between 0 and 255 to spawn this drop, // 0 being no chance and 255 being 100%. // : If specified, overrides the dropamount field of an ammoeffect // definition. Does not affect any other item effect type. If zero, this // field is ignored. // : Flag value. If specified as +toss, the item is a Heretic-style // item drop which will be thrown out during the A_Fall action function // with randomized velocity. If this flag is not specified, or is specified // as -toss, the item is a Doom-style drop item which will be spawned on the // floor as soon as the dying thing has reached 0 health. // Note: The older droptype field is still supported, and defines a Doom-style // dropitem (100% chance, no dropamount override, and never tossed). // dropitem.remove removes from this thingtype's dropitem list the named // EDF thingtype. Useful when inheriting. dropitem.remove // The cleardropitems flag, if present, removes ALL dropitems from a thingtype. // This is applied *before* any dropitem or droptype fields defined within this // thingtype itself. This allows removing all inherited dropitems at once. This // field is a flag and does not accept any value. Its presence in a thingtype // is not inheritable (things which inherit from this type must again specify // cleardropitems if they want to in turn remove any items this type added). cleardropitems // collectionspawn defines a thingtype at which THIS thingtype will select one // instance out of all instances on the map at which to spawn itself at level // start. collectionspawn [, [, [, ]]] // Explanation of collectionspawn multivalue properties: // * thingtype : Name of the EDF thingtype at which to spawn at random. If // this is invalid, this collectionspawn definition will be disregarded. // * spchance : if specified, chance this item will spawn at all in single // player, from 0 to 255. Default is 255. // * coopchance : if specified, chance this item will spawn at all in coop // mode, from 0 to 255. Default is 255. // * dmchance : if specified, chance this item will spawn at all in deathmatch // mode, from 0 to 255. Default is 255. // itemrespawnat defines an EDF thingtype at which this thingtype will respawn // if it becomes subject to Heretic-style item respawning. itemrespawnat // gibhealth overrides the gamemode default behavior for determining the // negative amount of health at which a thing uses its "extreme" death state // rather than its normal one. This is ordinarily defined in terms of the // spawnhealth (Doom and Strife thingtypes gib at -spawnhealth; Heretic and // Hexen thingtypes gib at -(spawnhealth/2). // // If an inheriting thingtype changes its spawnhealth, it will "lose" the // inherited definition of gibhealth from its parent. If changing spawnhealth // when inheriting from a thingtype that customizes gibhealth, be sure to // re-customize the gibhealth in the inheriting thingtype. gibhealth // If in the range of 0 to 24, this value overrides the "shift" amount that // enemies of this object experience while trying to aim at it due to // effects like SHADOW, GHOST, and TOTALINVISIBLE. A larger number in this // field makes enemies more inaccurate when aiming at this creature. The // default value of -1 means that no aiming inaccuracy is experienced // *except* what may be incurred from what flags this monster has. A value // larger than 24 will, on the other hand, override the creature's flags // and cause enemies to experience no inaccuracy due to to those flags // (so for example a creature inheriting from Spectre and setting its // aimshift to 25 will behave as though it does not have the SHADOW // flag other than for rendering purposes). Values of 20 and 21 are used // by the various built-in flag effects. aimshift } ---------------- New thing flags: ---------------- RAVENRESPAWN Specifies that a thingtype will undergo Raven-style (Heretic/Hexen) item respawning when picked up with item respawning enabled. Items which use this flag can define two special DECORATE-style states, one for the state sequence to use when waiting to respawn after being picked up, and another to be used when the object is going to be removed permanently. These states are specified as in the following two definitions from heretic/things.edf: thingtype HereticPickup { cflags SPECIAL|RAVENRESPAWN seesound ht_respawn states @" Pickup.Respawn: ACLO E 1400 A_HideThing ACLO A 4 A_RestoreSpecialThing1 ACLO BABCBCDC 4 ACLO D 4 A_RestoreSpecialThing2 stop "@ } thingtype HereticArtifact { cflags SPECIAL|RAVENRESPAWN seesound ht_respawn states @" Pickup.Respawn: ACLO DCDCBCBABA 3 ACLO A 1400 A_HideThing ACLO A 3 A_UnHideThing ACLO BABCBCDC 3 ACLO D 3 A_RestoreArtifact stop Pickup.Remove: ACLO DCDCBCBABA 3 stop "@ } When Pickup.Remove is not defined by such a thingtype, it will simply be removed from the level immediately, like a Doom-style item would. Five new action functions are provided that support this feature: A_HideThing : Sets DONTDRAW flag on an object A_UnHideThing : Unsets DONTDRAW flag on an object A_RestoreArtifact : Adds the SPECIAL flag back to an object, sets the object back into its spawnstate, and plays the object's seesound. A_RestoreSpecialThing1 : Removes the DONTDRAW flag from an object. If the object defines the itemrespawnat property, it will at this time be moved to a random spot if any such spots exist on the map (otherwise the item will remain where it spawned originally). The item will play its seesound. A_RestoreSpecialThing2 : Adds the SPECIAL flag back to an object and sets the object back into its spawnstate. NOTSHAREWARE Things with this flag will not spawn on a map if the current gamemode is a shareware gamemode. NOTORQUE Things with this flag are never subject to MBF torque simulation, even if it is enabled via the compatibility vector. ALWAYSTORQUE Things with this flag are always subject to MBF torque simulation, even if it is disabled via the compatibility vector. NOZERODAMAGE Projectiles given this flag don't inflict damage on objects if the damage they would inflict is 0. This prevents pain animation, anger, and spawning of any blood (in Heretic eventually, unfinished as of yet). TLSTYLESUB Thingtype uses subtractive blending. TOTALINVISIBLE Thing is "totally" invisible to monsters. For players, this means that monsters will not wake up unless a noise is made. Once enemies are alerted via noise being made, they will aim inaccurately with the same effect as the SHADOW flag. This flag does not imply that the thing displays no sprite, however. Combine with DONTDRAW to accomplish that effect. Note that "AMBUSH" things do not wake up unless they take direct damage, since they also do not hear the player. -------------------- DECORATE state flags -------------------- A "fast" flag is now allowed between the tics and action function of DECORATE states (along with the pre-existing "bright" flag) which determines if that state halves its "tics" value when the game is in -fast or Nightmare skill. Example (from Demon's states): states @" See: SARG AABBCCDD 2 fast A_Chase loop Melee: SARG EF 8 fast A_FaceTarget SARG G 8 fast A_SargAttack goto See Pain: SARG H 2 fast SARG H 2 fast A_Pain goto See "@ ------------------------------------------------------------------------------- EDF Sound Environments ------------------------------------------------------------------------------- Use of sound environments allows addition of reverberation effects to areas within levels called "sound zones." Sound zones are sets of contiguous sectors which connect to each other by two-sided lines which are not marked with a new ExtraData linedef flag, ZONEBOUNDARY. To assign a specific sound environment to a zone, use ExtraData to create an EESoundEnvironment object in one of the sectors inside that zone with its first two map arguments set to the two ID numbers of the EDF reverb definition you want to apply while a player is inside that area. // Defines a reverb sound environment. ID1 and ID2 are required and must be // numbers between 0 and 255. reverb : , { // Roomsize defines the decay time and "volume" of reverberation; the larger // the value, the bigger the space. // Range 0.0 to 1.07143; default 0.5 roomsize // Damping defines the amount of high-frequency rolloff in the reverb filters. // A higher value is analogous to a space filled with fewer reflective objects. // Range 0.0 to 1.0; default 0.5 damping // Wet scale defines the amount of reverberated signal in the reverb output. // Range 0.0 to 1.0; default 0.333... wetscale // Dry scale defines the amount of dry (input) signal in the reverb output. // Range 0.0 to 1.0; default 0.0 dryscale // Width defines the amount of stereo phasing/cross-over in the reverberation. // Range 0.0 to 1.0; default 1.0 width // Predelay defines the amount of time between sound emission and the first // reverb response. Defined in milliseconds; Range 0 to 250; default 0. predelay // The equalized flag, if specified as +equalized, will turn on a three-band // equalization pass after the reverb filters. This allows tweaking the amount // of low- and high-frequency sound for adjusting the "luminosity" of the // effect. Default is -equalized. [+-]equalized // These parameters apply when +equalized is specified: eq.lowfreq // Low band upper edge in Hz; 20-20000; default = 250.0 eq.highfreq // High band lower edge in Hz; 20-20000; default = 4000.0 eq.lowgain // Volume factor for low freqs; 0.0-1.0; default 1.0 eq.midgain // Volume factor for mid freqs; 0.0-1.0; default 1.0 eq.highgain // Volume factor for hi freqs; 0.0-1.0; default 1.0 } Adjustments have also been made to EDF ambience and soundsequence definitions which allow either to exclude themselves from application of sound zones. To exclude either type of definition from environmental effects, use the -reverb flag as such: ambience { ... -reverb } soundsequence { ... -reverb } By default, environments apply to all ambience and soundsequence definitions. ------------------------------------------------------------------------------- New EDF Thingtypes ------------------------------------------------------------------------------- base/things.edf: EESoundEnvironment : DoomEd 9048 Partially ZDoom-compatible method of assigning an environmental effect to a sound zone. This thingtype uses its first two map arguments as the ID1 and ID2 to match an EDF reverb definition and assigns that definition to its spawn sector's sound zone. base/doom/things.edf: EENightmareSpectre : DoomEd 889, DeHackEd 158 Implements PlayStation Doom's subtractively blended spectre w/300 spawnhealth. EEPSXSpectre : DoomEd 890, DeHackEd 159 Implements PlayStation Doom's additive spectre. EEPSXBloodyChain : DoomEd 891, DeHackEd 160 Implements PlayStation Doom's bloody chain decorative object. A sprite is not included in eternity.pke. Requires BLCHA0 to be useful. EEBetaLostSoul : DoomEd 9037, DeHackEd 161 Slightly edited Lost Soul from the press release beta version of Doom. ------- Special ------- DOOM thingtypes can now be spawned in other gamemodes' maps via use of DoomEd numbers in the 6000 range. For a normal thingtype with a DoomEd number between 0 and 255, simply add 6000 to its DoomEd number. For example the Arch-vile, with a normal DoomEd number of 64, can be spawned in Heretic using DoomEd number 6064. For DoomEd numbers in the 2000 and 3000 ranges, subtract 2000 or 3000 respectively and then add 6200 or 6300, respectively. For example, 3001 DoomImp can be spawned in Heretic using DoomEd number 6301.