catch_death_act

Response Typescript
EntitiesRooms, Mobiles, Objects
Parameters-

    This trigger fires when a mobile dies and can be caught by the room in
which they die or by any mobiles or objects present in the room.

@n, @attacker - The attacker, if any, that killed the mob.

@t, @victim - The mob that has died, just before it is purged.

@o, @corpse - The corpse object that is created for the death.
Note: inventory and equipment are still on the
mobile when this trigger fires.

@x, @victimName - The name of the mobile that died.

@deathType - The manner of death occurring.

Corpses contain a small amount of useful information about what they were
when alive; however, without copying the entire mobile structure they
cannot keep track of all the information. For this reason the
catch_death_act passes the soon to be purged mob pointer in @n. Thus your
script can retrieve any information about the mob provided a protected
block exists at the beginning of the script in which any necessary
information is saved to variables. If you do not use a protected block
then there is no guarantee how far along your script will get before the
@n becomes a null pointer. When @n becomes null, all attempts to retrieve
data will also return null.

The type of death occuring can be determined by the value of @deathType.
So far the following values exist:

airLack - this occurs when the mobile drowns

damage - this generally occurs in combat

deathtrap - sucker hit a deathtrap

fall - this occurs when fly wear off

gladiator - gladiator mode death

noPenalty - no panalty death (noobs usually)

pkill - killed by another player

rebirth - player has enabled rebirth

slay - npcslay or one of the other slay commands

sunlight - this occurs when vampires get roasted in the sun

waterLack - this occurs when a waterOnly mobile is out of water