Sector

From ZDoom Wiki

(Redirected from SECTORS)
Jump to: navigation, search

A sector is an enclosed area made up of lines in the map. Sectors are referenced by the Sidedefs linked to the enclosing Linedefs. Sectors must be closed areas, as in all sidedefs that reference them must make up one or more closed shapes. Note that having unclosed sectors is possible, and can be used for a few special effects, but can cause unpredictable results (including crashes) if used incorrectly.

As stated, a sector need not enclose only one area of the map. To avoid redundancy, two separate areas of the map could be defined by one sector, thus copying all the properties of one area to the other. However, be aware that the engine treats these separate shapes as the same sector. In particular, sounds entering one area of the sector will be heard by enemies in the other. This can be used intentionally to allow sounds generated in one area of the map to alert enemies in another, unconnected area.


Specification

Bytes Data Type Description Notes
0-1 Signed Short Floor height
2-3 Signed Short Ceiling height
4-11 Char Floor texture
12-19 Char Ceiling texture
20-21 Unsigned Short Light level Vanilla Doom rounded the light level to the nearest multiple of 8, ZDoom shows unique light levels for all 256 values
22-23 Unsigned Short Sector special Sector specials
24-25 Unsigned Short Linedef / Thing tag Action Specials
Personal tools