Ghost monster

''This article is about the bug in Doom II. For informaton about the Heretic monster type, see Ghosts (Heretic)''

Ghost monsters are caused by a rare bug that occurs when a monster's corpse is crushed under a door or ceiling and then resurrected by an Arch-Vile. These ghosts behave like the monsters they formerly were, except that they can sometimes pass through walls and can only be harmed by splash damage, monster melee attacks, and telefragging.

This bug is fixed in nearly all source ports. However, some PWADs have used the ghost monster phenomenon as a feature. Boom and its close derivatives can be set to allow or disallow the creation of ghost monsters according to the user's preference.

In extremely rare cases, a memory overflow can occur which causes all Things, including players and monsters, to become ghosts. In deathmatch play, this phenomenon is termed the DM no-clipping bug.

Code
The following code creates pools of blood: P_SetMobjState (thing, S_GIBS);

thing->flags &= ~MF_SOLID; thing->height = 0; thing->radius = 0;

The parameters are not restored upon resurrection, so all such pools of blood are potential ghosts.