Editing EDF lockdefs

From Eternity Wiki
Jump to navigationJump 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.

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:
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. For [[ACS_LockedExecute]] and [[Door_LockedRaise]], it is possible to use it as a number parameter.
Define what happens when locked lines are activated. For Doom and Heretic map formats, the lockdef IDs used by certain linedefs are hardcoded. For ACS_LockedExecute and Door_LockedRaise, it is possible to use it as a number parameter.


A lockdef defining the same unique ID number as a previous definition will overwrite that previous definition.
A lockdef defining the same unique ID number as a previous definition will overwrite that previous definition.
Line 7: Line 7:
Default [[lock identifiers]] are listed on this wiki.
Default [[lock identifiers]] are listed on this wiki.


==Syntax==
  lockdef <unique id number>
  lockdef <unique id number>
  {
  {
  require <item name 1>
  require <str> // Name of a Key artifact type the player must have in his/her
  require <item name 2>
                // inventory for the lock to activate. Any number of keys can
  ...
                // be required by specifying this field more than once.
 
 
  any { keys: <key> [, <key>]* }
  // An "any" section, of which there can be any number, defines a set of keys
  any { keys: <key> [, <key>]* }
  // out of which the player must possess *at least one* in each "any" section.
  ...
  // There can be any number of these sections defined.
 
  any    
  message <text>
  {
  remotemessage <text>
    keys <key> [, <key>]* // list of one or more Key artifact types
  lockedsound <name>
  }
  mapcolor <string>
 
  message       <str> // Message to give if manual lock activation fails. If
                      // this string starts with a $, it is a BEX string
                      // mnemonic.
 
  remotemessage <str> // Message to give if remote lock activation fails. If
                      // this string starts with a $, it is a BEX string
                      // mnemonic.
                     
  lockedsound <str>  // 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 <str>
  }
  }
==Explanation==
 
*'''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.
*'''any'''
: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.
*'''message'''
:Default: (don't show message)
:Message to give if manual lock activation fails. If this string starts with a $, it is a [[Dehacked|BEX]] string mnemonic.
*'''remotemessage'''
:Default: (show '''message''' instead)
:Message to give if remote lock activation fails. If this string starts with a $, it is a BEX string mnemonic.
*'''lockedsound'''
:Default: (none)
:Name of EDF sound to play when lock activation fails. If unspecified, the player's skin "oof" sound is used as normal.
*'''mapcolor'''
: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.
[[Category:EDF]]
[[Category:EDF]]
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)