# Detailed generalized linedef specification

BOOM has added generalized linedef types that permit the parameters of linedef actions to be nearly independently chosen. They work as half-way between regular/Boom extended linedef types and Eternity parameterized types. Unlike the latter, they are meant to be called directly from Doom format maps, without requiring ExtraData or a more advanced map format, but unlike them, they can only be given a few set values, which in some cases may be insufficient.

*Back to Linedef types*

== Generalized Linedef Ranges ======================================= There are types for Floors, Ceilings, Doors, Locked Doors, Lifts, Stairs, and Crushers. The allocation of linedef type field numbers is according to the following table: Type Start Length (Dec) ----------------------------------------------------------------- Floors 0x6000 0x2000 (8192) Ceilings 0x4000 0x2000 (8192) Doors 0x3c00 0x0400 (1024) Locked Doors 0x3800 0x0400 (1024) Lifts 0x3400 0x0400 (1024) Stairs 0x3000 0x0400 (1024) Crushers 0x2F80 0x0080 (128) ----------------------------------------------------------------- Totals: 0x2f80-0x7fff 0x5080 (20608) ======================================================================

The following sections define the placement and meaning of the bit fields within each linedef category. Fields in the description are listed in increasing numeric order.

Some nomenclature:

Target height designations:

H means highest, L means lowest, N means next, F means floor, C means ceiling, n means neighbor, Cr means crush, sT means shortest lower texture.

Texture change designations:

c0n change texture, change sector type to 0, numeric model change c0t change texture, change sector type to 0, trigger model change cTn change texture only, numeric model change cTt change texture only, trigger model change cSn change texture and sector type to model's, numeric model change cSt change texture and sector type to model's, trigger model change

A trigger model change uses the sector on the first side of the trigger for its model. A numeric model change looks at the sectors adjoining the tagged sector at the target height, and chooses the one across the lowest numbered two sided line for its model. If no model exists, no change occurs. Note that in DOOM II v1.9, no model meant an illegal sector type was generated.

------------------------------------------------------------------ generalized floors (8192 types) field description NBits Mask Shift ------------------------------------------------------------------ trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 model trig/numeric -or- nomonst/monst 1 0x0020 5 direct down/up 1 0x0040 6 target HnF/LnF/NnF/LnC/C/sT/24/32 3 0x0380 7 change nochg/zero/txtonly/type 2 0x0c00 10 crush no/yes 1 0x1000 12

DETH Nomenclature:

W1[m] F->HnF DnS [c0t] [Cr] WR[m] F->LnF DnN [c0n] S1[m] F->NnF DnF [cTt] SR[m] F->LnC DnT [cTn] G1[m] F->C UpS [cSt] GR[m] FbysT UpN [cSn] D1[m] Fby24 UpF DR[m] Fby32 UpT

Notes: 1) When change is nochg, model is 1 when monsters can activate trigger otherwise monsters cannot activate it. 2) The change fields mean the following: nochg - means no texture change or type change zero - means sector type is zeroed, texture copied from model txtonly - means sector type unchanged, texture copied from model type - means sector type and floor texture are copied from model 3) down/up specifies the "normal" direction for moving. If the target specifies motion in the opposite direction, motion is instant. Otherwise it occurs at speed specified by speed field. 4) Speed is 1/2/4/8 units per tic 5) If change is nonzero then model determines which sector is copied. If model is 0 its the sector on the first side of the trigger. if model is 1 (numeric) then the model sector is the sector at destination height on the opposite side of the lowest numbered two sided linedef around the tagged sector. If it doesn't exist no change occurs.

------------------------------------------------------------------ generalized ceilings (8192 types) field description NBits Mask Shift ------------------------------------------------------------------ trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 model trig/numeric -or- nomonst/monst 1 0x0020 5 direct down/up 1 0x0040 6 target HnC/LnC/NnC/HnF/F/sT/24/32 3 0x0380 7 change nochg/zero/txtonly/type 2 0x0c00 10 crush no/yes 1 0x1000 12 DETH Nomenclature: W1[m] C->HnC DnS [Cr] [c0t] WR[m] C->LnC DnN [c0n] S1[m] C->NnC DnF [cTt] SR[m] C->HnF DnT [cTn] G1[m] C->F UpS [cSt] GR[m] CbysT UpN [cSn] D1[m] Cby24 UpF DR[m] Cby32 UpT Notes: 1) When change is nochg, model is 1 when monsters can activate trigger otherwise monsters cannot activate it. 2) The change fields mean the following: nochg - means no texture change or type change zero - means sector type is zeroed, texture copied from model txtonly - means sector type unchanged, texture copied from model type - means sector type and ceiling texture are copied from model 3) down/up specifies the "normal" direction for moving. If the target specifies motion in the opposite direction, motion is instant. Otherwise it occurs at speed specified by speed field. 4) Speed is 1/2/4/8 units per tic 5) If change is nonzero then model determines which sector is copied. If model is 0 its the sector on the first side of the trigger. if model is 1 (numeric) then the model sector is the sector at destination height on the opposite side of the lowest numbered two sided linedef around the tagged sector. If it doesn't exist no change occurs. ------------------------------------------------------------------ generalized doors (1024 types) field description NBits Mask Shift ------------------------------------------------------------------ trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 kind odc/o/cdo/c 2 0x0060 5 monster n/y 1 0x0080 7 delay 1/4/9/30 (secs) 2 0x0300 8 DETH Nomenclature: W1[m] OpnD{1|4|9|30}Cls S WR[m] Opn N S1[m] ClsD{1|4|9|30}Opn F SR[m] Cls T G1[m] GR[m] D1[m] DR[m] Notes: 1) The odc (Open, Delay, Close) and cdo (Close, Delay, Open) kinds use the delay field. The o (Open and Stay) and c (Close and Stay) kinds do not. 2) The precise delay timings in gametics are: 35/150/300/1050 3) Speed is 2/4/8/16 units per tic ------------------------------------------------------------------ generalized locked doors (1024 types) field description NBits Mask Shift ------------------------------------------------------------------ trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 kind odc/o 1 0x0020 5 lock any/rc/bc/yc/rs/bs/ys/all 3 0x01c0 6 sk=ck n/y 1 0x0200 9 DETH Nomenclature: W1[m] OpnD{1|4|9|30}Cls S Any WR[m] Opn N R{C|S|K} S1[m] F B{C|S|K} SR[m] T Y{C|S|K} G1[m] All{3|6} GR[m] D1[m] DR[m] Notes: 1) Delay for odc kind is constant at 150 gametics or about 4.333 secs 2) The lock field allows any key to open a door, or a specific key to open a door, or all keys to open a door. 3) If the sk=ck field is 0 (n) skull and cards are different keys, otherwise they are treated identically. Hence an "all" type door requires 3 keys if sk=ck is 1, and 6 keys if sk=ck is 0. 4) Speed is 2/4/8/16 units per tic ------------------------------------------------------------------- generalized lifts (1024 types) field description NBits Mask Shift ------------------------------------------------------------------- trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 monster n/y 1 0x0020 5 delay 1/3/5/10 (secs) 2 0x00c0 6 target LnF/NnF/LnC/LnF<->HnF(perp.) 2 0x0300 8 DETH Nomenclature: W1[m] Lft F->LnFD{1|3|5|10} S WR[m] F->NnFD{1|3|5|10} N S1[m] F->LnCD{1|3|5|10} F SR[m] HnF<->LnFD{1|3|5|10} T G1[m] GR[m] D1[m] DR[m] Notes: 1) The precise delay timings in gametics are: 35/105/165/350 2) Speed is 1/2/4/8 units per tic 3) If the target specified is above starting floor height, or does not exist the lift does not move when triggered. NnF is Next Lowest Neighbor Floor. 4) Starting a perpetual lift between lowest and highest neighboring floors locks out all other actions on the sector, even if it is stopped with the non-extended stop perpetual floor function. ------------------------------------------------------------------- generalized stairs (1024 types) field description NBits Mask Shift ------------------------------------------------------------------- trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 monster n/y 1 0x0020 5 step 4/8/16/24 2 0x00c0 6 dir dn/up 1 0x0100 8 igntxt n/y 1 0x0200 9 DETH Nomenclature: W1[m] Stair Dn s4 S [Ign] WR[m] Up s8 N S1[m] s16 F SR[m] s24 T G1[m] GR[m] D1[m] DR[m] Notes: 1) Speed is .25/.5/2/4 units per tic 2) If igntxt is 1, then the staircase will not stop building when a step does not have the same texture as the previous. 3) A retriggerable stairs builds up and down alternately on each trigger. ------------------------------------------------------------------- generalized crushers (128 types) field description NBits Mask Shift ------------------------------------------------------------------- trigger W1/WR/S1/SR/G1/GR/D1/DR 3 0x0007 0 speed slow/normal/fast/turbo 2 0x0018 3 monster n/y 1 0x0020 5 silent n/y 1 0x0040 6 DETH Nomenclature: W1[m] Crusher S [Silent] WR[m] N S1[m] F SR[m] T G1[m] GR[m] D1[m] DR[m] Notes: 1) Speed is 1/2/4/8 units per second, faster means slower damage as usual. 2) If silent is 1, the crusher is totally quiet, no start/stop sounds