Making superposed sectors

From DoomWiki.org

Revision as of 16:11, 2 July 2005 by CarlosHoyos (talk | contribs) ((rewording))


A Superposed sector is a sector that overlays another sector of same shape. The sectors are not connected, and the overlayed sector must contain a diagonal linedef crossing it to avoid visual glitches. Superposed sectors are like ghosts: they can be seen but are not solid. The main use for this effect is to simulate deep water and false floor traps.

Implementation

The following method is the one included in Bug's Revolutionary Techniques for Doom and Doom II v2.3 guide, which has defined textures for the bottom of the pit. Notice that this trick does not work in some source ports like EDGE, as the trick is not standard.

Steps:

  • Trace a big enough sector to contain two identical copies of the pool sector. The first one will be defined as the bottom of the pool, and the second will be the surface.
  • Define the values for the surface. The only requirement is that the floor height has to be the same of the surrounding sector. It is a good idea to put the same light level, though, and also F_SKY1 as the ceiling texture.
  • Define the values for the bottom. I suggest a light level of 100-110, using F_SKY1 as the ceiling texture, and some kind of sand as the floor texture. For a pool, a depth of 200 is also recommended.
  • Choose textures for the linedefs of the bottom.
  • On the bottom sector, trace a two-sided linedef from the lower left corner to the upper right corner without texture. If the sector has the shape of a triangle, try adding an extra vertex on it.
  • Move the surface exactly over the bottom, but don't join vertexes.

After this, the trick should be done.

Limitations

  • Objects inside the pool are drawn over the texture. Using a low light level for the bottom of the pool may help to hide some non-luminescent objects inside it.
  • If the floor height of the water surface is lower than the one of the surrounding sector, the bottom sector will not have texture. This is because then the texture is only applied on the walls above the water level. To avoid this problem, place the surrounding sector inside another sector with more height, and then make it really thin.
  • If the pool is too depth, the player cannot escape from it.

Example

Media:Deep_Water.WAD (file info) is an example of this trick. The advantages of using F_SKY1 as the ceiling texture is that you can put different light levels on the pool sectors without the player noticing beforehand, as the ceil does not reflect this. There seems to be a way to avoid this, though, but that would require the use of another trick.