SWITCHES

The SWITCHES lump is a Boom feature for defining additional switches. Although some modern editors such as SLADE 3 allow to create and edit this lump directly in binary form, the original method devised by TeamTNT involved creating a text file and converting it with a small utility called (switch and animation tables). SWITCHES lumps are supported by all Boom compatible ports and Doomsday.

SWITCHES lumps are not cumulative; only the last one loaded will be used.

Format
SWITCHES is a series of 20 byte entries: The last entry, with a 0 in its final two bytes, is not used.

If a switch is defined while its textures are not present, the vanilla engine will complain, which is why this tiered approach was adopted by id Software originally, and also why Doom II contains some identical switch definitions that are never used in its maps; they correspond to switches from Doom that were dummied out to prevent errors.

Swantbls syntax
The tool converts a plain text file into an ANIMATED and SWITCHES lump. The format of the plain text file prior to conversion is as follows (quoth defswani.dat):

# [SWITCHES] 1      SW1BRCOM        SW2BRCOM ...
 * 1) This file is input for SWANTBLS.EXE, it specifies the switchnames
 * 2) and animated textures and flats usable with BOOM. The output of
 * 3) SWANTBLS is two lumps, SWITCHES.LMP and ANIMATED.LMP that should
 * 4) be inserted in the PWAD as lumps.
 * 1) switches usable with each IWAD, 1=SW, 2=registered DOOM, 3=DOOM2
 * 1) epi   texture1        texture2

[FLATS] 8      NUKAGE3     NUKAGE1 ...
 * 1) animated flats, spd is number of frames between changes
 * 1) spd   last        first

[TEXTURES] 8      BLODGR4     BLODGR1 ...
 * 1) animated textures, spd is number of frames between changes
 * 1) spd   last        first