Monster closet is a slang term that describes a small portion of a level that contains one or more enemies and is initially sealed off from the rest of the map, usually designed to function as a remotely activated trap. The term is often used with a negative connotation; this element of gameplay as it appears in Doom and elsewhere is popularly derided for being unimaginative, unrealistic, or immersion-breaking. Nonetheless, it is one of the fundamental building blocks of Doom levels both past and present.
Doom and Doom II
The monster closet is a pacing mechanic that adds a layer of complexity to the ways authors can introduce enemies to the player. Without some kind of monster closet, enemies are typically either immediately visible as the player enters their associated area or hidden in a corner, alcove, or behind some piece of level geometry. Some of them can be teased out of their positions if the player attacks with a weapon, alerting them. Those that are flagged with the ambush property will wait until they "see" the player before attacking. Monster closets complicate gameplay by obscuring enemies so that they are not immediately apparent and then releasing them as the author desires without having to construct a teleporter trap.
A typical monster closet consists of a small, rectangular adjunct to the playing area that is sealed off with a door (hence the term, "monster closet") that only opens once the player has activated its associated trigger. This may be in response to meeting an obvious progression objective, obtaining a powerup, or as an incidental trap. They may also be constructed as platforms that are raised into the level's ceiling, appearing first as columns or some other part of the level's geometry before lowering into the playing area. A monster closet does not necessarily open to immediately ambush the player. It may be as far from the trigger as the author desires, introducing new enemies into a previously explored portion of the level. Such monsters may lie in wait or roam free once awakened; the latter example allows for more "organic" ambush scenarios as enemies have an opportunity to sneak up on the player. It may also be a source of tension as the player is not normally aware of when these monsters were awakened, the size of their force, their composition, or even their location, outside of the sounds generated as they close in. This can be especially effective if the monsters released include any arch-viles, which may resurrect other monsters already killed by the player.
Monster closets may contain health or ammo in addition to or in lieu of enemies. This is one way to ensure that the player is compensated for resources that he or she may use in the process of defeating the monsters, streamlining the level's pacing. Depending on the setup, they may also contain switches or other elements that are important to the level's progression. For instance, a common trap setup locks the player in a room after he or she enters and then opens up monster closets for an ambush. The switch to open the sealed door is then found in one of the alcoves. Monster closets are not necessarily accessible by the player; they may be gated off by something like an impassable linedef or an elevated position. While this prevents landbound enemies from directly confronting the player, a raised attack vector adds an additional dynamic to encounters. Using an elevated closet for a flying monster ensures that it enters play at a height superior to the player.
Authors may attempt to mask the utilitarian nature of monster closets by making them feel more like natural extensions of the playing area. This may be accomplished by developing the design of the closet beyond a relatively featureless rectangle into a memorable portion of the level in its own right. Some authors work them into the level's narrative action by making it seem as though monsters have torn through the walls or emerged from sections of the level that have undergone some sort of Hellish transformation. They may also serve as passages to entirely new sections of the level, though this may confuse players who are accustomed to checking doors for changes in available routes.
Monster closets are usually not designed in such a fashion that the monster is woken up before the door opens, but there are instances where this occurs (Doom II's MAP01). On these rare occasions, the monster typically leaves the closet of its own volition, opening the door from the inside. The roaming sounds made by monsters trapped inside such a closet can create tension, but also give away the existence of a trap.