<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://wiki.slothmud.com/wiki/index.php?action=history&amp;feed=atom&amp;title=MUDL%3AEvery_death</id>
		<title>MUDL:Every death - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://wiki.slothmud.com/wiki/index.php?action=history&amp;feed=atom&amp;title=MUDL%3AEvery_death"/>
		<link rel="alternate" type="text/html" href="http://wiki.slothmud.com/wiki/index.php?title=MUDL:Every_death&amp;action=history"/>
		<updated>2026-05-19T11:11:30Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>http://wiki.slothmud.com/wiki/index.php?title=MUDL:Every_death&amp;diff=65146&amp;oldid=prev</id>
		<title>Teker: Created page with &quot; __TOC__  = Overview =  This MUDL function gets called each time a character is killed.  It is called after the death cry and before every_corpse occurs.  This function is val...&quot;</title>
		<link rel="alternate" type="text/html" href="http://wiki.slothmud.com/wiki/index.php?title=MUDL:Every_death&amp;diff=65146&amp;oldid=prev"/>
				<updated>2017-05-18T16:47:39Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot; __TOC__  = Overview =  This MUDL function gets called each time a character is killed.  It is called after the death cry and before every_corpse occurs.  This function is val...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Overview =&lt;br /&gt;
&lt;br /&gt;
This MUDL function gets called each time a character is killed.  It is called after the death cry and before every_corpse occurs.  This function is valid for items in the room, items carried and worn by characters in the room, mobiles in the room, the room, and the area.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Command Syntax =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
addproc &amp;lt;mobile&amp;gt; mudl&lt;br /&gt;
setproc &amp;lt;mobile&amp;gt; ## every_death&lt;br /&gt;
&lt;br /&gt;
addproc &amp;lt;item&amp;gt; mudl&lt;br /&gt;
setproc &amp;lt;item&amp;gt; ## every_death&lt;br /&gt;
&lt;br /&gt;
addproc room mudl&lt;br /&gt;
setproc room ## every_death&lt;br /&gt;
&lt;br /&gt;
addproc area mudl&lt;br /&gt;
setproc area ## every_death&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Global Variables =&lt;br /&gt;
&lt;br /&gt;
The following global variables are available:&lt;br /&gt;
{|class=&amp;quot;abilitiestable&amp;quot; border=&amp;quot;0&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
! Name !! Type !! Description&lt;br /&gt;
|-&lt;br /&gt;
| %a&lt;br /&gt;
| Character&lt;br /&gt;
| The character that performed the kill.&lt;br /&gt;
|-&lt;br /&gt;
| %x&lt;br /&gt;
| Character&lt;br /&gt;
| The character that died.&lt;br /&gt;
|-&lt;br /&gt;
| %c&lt;br /&gt;
| Character&lt;br /&gt;
| The mobile that has the MUDL script is attached to or null if it's a room or area script.&lt;br /&gt;
|-&lt;br /&gt;
| %room&lt;br /&gt;
| Room&lt;br /&gt;
| The room in the game where the kill occurred.&lt;br /&gt;
|-&lt;br /&gt;
| %area&lt;br /&gt;
| Area&lt;br /&gt;
| The area (zone) in the game where the kill occurred.&lt;br /&gt;
|-&lt;br /&gt;
| %parent&lt;br /&gt;
| Character or Room or Area&lt;br /&gt;
| The in-game element that the MUDL script is attached to.  It will be identical to %c or %room or %area.&lt;br /&gt;
|-&lt;br /&gt;
| %procedure_index&lt;br /&gt;
| Integer&lt;br /&gt;
| The index of the current MUDL procedure on the %parent variable.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Return Values =&lt;br /&gt;
&lt;br /&gt;
The return value from this function is ignored.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Triggered Scripts =&lt;br /&gt;
&lt;br /&gt;
Events are triggered in the following order:&lt;br /&gt;
# Every_death scripts are triggered on items worn by characters in the room (and their clasps and runes).&lt;br /&gt;
# Every_death scripts are triggered on items on the floor in the room (and their clasps, but not runes).&lt;br /&gt;
# Every_death scripts are triggered on items carried by the killer (and their clasps and runes).&lt;br /&gt;
# Every_death scripts are triggered on the items carried by the character who was killed (and their clasps and runes).&lt;br /&gt;
# Every_death scripts are triggered on the mobiles in the room (including the killer and character that was killed).&lt;br /&gt;
# Every_death scripts are triggered on the room.&lt;br /&gt;
# Every_death scripts are triggered on the area.&lt;br /&gt;
# All every_corpse scripts are run after every_death.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Examples =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
addproc &amp;lt;mobile&amp;gt; mudl&lt;br /&gt;
&lt;br /&gt;
setproc &amp;lt;mobile&amp;gt; ## every_death&lt;br /&gt;
msg_room(%room, 'DEATH!'),&lt;br /&gt;
msg_room(%room, 'DEATH! c = ' + name(%c)),&lt;br /&gt;
msg_room(%room, 'DEATH! a = ' + name(%a)),&lt;br /&gt;
msg_room(%room, 'DEATH! x = ' + name(%x)),&lt;br /&gt;
msg_room(%room, 'DEATH! room = ' + name(%room)),&lt;br /&gt;
msg_room(%room, 'DEATH! area = ' + name(%area)),&lt;br /&gt;
return(false)&lt;br /&gt;
@&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
setproc &amp;lt;mobile&amp;gt; ## PROC_ENABLED 1&lt;br /&gt;
compile&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Notes ==&lt;br /&gt;
&lt;br /&gt;
The killer %a may be equal to the actor %x if the character died from a trap, poison, or some other method where a specific killer doesn't exist or can not be found.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Building]]&lt;br /&gt;
[[Category:MUDL|Every_corpse]]&lt;/div&gt;</summary>
		<author><name>Teker</name></author>	</entry>

	</feed>