Lost soul colliding with items

From DoomWiki.org

If a lost soul collides with any item while charging forward, the monster will stop and start moving normally again as if nothing had happened. A notable example can be seen on E2M8: Tower of Babel in Doom: as long as the player stays behind the items in alcoves, he is effectively unreachable for the flaming skulls in the level.

The reasoning behind this behavior does not seem very obvious. In the Doom source code, PIT_CheckThing is the generic function which handles collisions between things - such as projectile hits and items being picked up. Here, projectiles (mobjs which have the MF_MISSILE bitflag onto them) are checked if they actually hit something solid and/or shootable, taking the Z coordinate into account (the function returns true if the collision does not take place):[1]

  // missiles can hit other things
  if (tmthing->flags & MF_MISSILE)
        // see if it went over / under
        if (tmthing->z > thing->z + thing->height)
           return true;		// overhead
        if (tmthing->z+tmthing->height < thing->z)
           return true;		// underneath

For reasons unknown, the lost soul's collision code (while dashing, it has the MF_SKULLFLY bitflag set, albeit the difference is not significant) does not do any of above checks, simply zeroing out the monster's momentum, along with a call to P_DamageMobj. Furthermore, it does not check what kind of thing it hits (flags MF_SOLID, MF_SPECIAL, MF_SHOOTABLE, which again are handled proper for missiles).

The result of such flawed logic is, that the lost soul's charge will be interrupted by any type of thing - a monster, a powerup, or a decoration - situated on any height along the lost soul's trajectory.

External Links[edit]

Bug report thread at the ZDoom forums


  1. Doom source code, p_map.c