A_BossDeath
A_BossDeath
(no parameters)
Checks whether all monsters of the calling type are dead, and if so, executes all special actions that are assigned to this type. Special actions have to be assigned to a monster with the SpecialAction MAPINFO command.
Examples
The Baron of Hell, for example, uses A_BossDeath in its Death sequence - that is called in E1M8 when both barons have died, and thus performs the map's special action (in this case, lower the walls).
Death: BOSS I 8 BOSS J 8 A_Scream BOSS K 8 BOSS L 8 A_NoBlocking BOSS MN 8 BOSS O -1 A_BossDeath Stop
Interaction with actor replacement
If the calling actor's class replaces actors of another class, this function will also trigger special actions for that other class. If more than one actor class is declared as replacing the same base actor, and actors of both classes are present on the map at the same time, then the same special action may be triggered more than once, potentially breaking the map.
For example, if a mod adds several variants of the Arachnotron (all of which are declared with replaces Arachnotron
), and spawns the different variants at random (with an actor that also replaces Arachnotron
), then the map may break when the player kills them all. (This won't happen when using a RandomSpawner, because it specially handles this situation.)