From the NannyMUD documentation

LAST CHANGE

 2000-09-01

NAME

        sould - The soul daemon.

INHERITS

/std/stationary
/obj/hook

INCLUDES

soul.h
/std/soul/soul_data.h

LOCATION

	/std/soul/sould.c

FUNCTIONS

SETUP FUNCTIONS

 	You can add and remove extra feelings from the soul daemon
	from your objects by using the following functions:

	add_verb
	remove_verb
	add_adverb
	remove_adverb

OTHER FUNCTIONS

	reduce_verb

	These hooks are available in the soul daemon:

	feeling_hook
	block_feeling_hook

DESCRIPTION

	The soul daemon is the object that handles everything concerning
	feelings. The player soul communicates with it to produce nice
	feelings for the players. The soul daemon uses tags to specify
	where feelings belong.

	TAGS

	The tag should be a name like "khorne", "Gabe", "voter", etc.
	That is, a lower case word if it's a club or guild, and your
	name if it's your personal feelings. It is a bad thing to 
	modify someone else's tags.

	Priority means that in case of a conflict between two tags,
	the higher priority tag will be chosen. Guild tags should be
	higher priority than club tags. I suggest 10 for guild tags
	and 5 for club tags.

SEE ALSO

        soul in std/soul/soul

SEE ALSO

        verb format in std/soul/verb_format

SEE ALSO

        feelings in std/soul/feelings
        feelings in wizinfo/feelings

SEE ALSO

        feeling_hook in std/soul/feeling_hook

FUNCTION


NAME

        add_verb - Add extra verbs to the soul daemon.

SYNTAX

	void add_verb(mapping verbs, string tag, int priority)

DESCRIPTION

	This function adds verbs to the soul daemon. They will stay
	there until removed or until the game reboots. The argument
	verbs is of the verb_format type. The verbs added will be
	associated with the given tag. The tag will be given the
	specified priority.

FUNCTION


NAME

        remove_verb - Remove extra verbs from the soul daemon.

SYNTAX

	void remove_verb(string *verbs, string tag)

DESCRIPTION

	This function removes verbs previously added by add_verb.
	Only verbs associated with the tag will be removed.

FUNCTION


NAME

        add_adverb - Add extra adverbs to the soul daemon.

SYNTAX

	void add_adverb(string *adverbs, string tag)

DESCRIPTION

	With this function you can add adverbs to the soul daemon.
	The adverbs will be associated with the given tag.

FUNCTION


NAME

        remove_adverb - Remove extra adverbs from the soul daemon.

SYNTAX

	void remove_adverb(string *adverbs)

DESCRIPTION

	This function removes adverbs previously added with
	add_adverb. Only adverbs associated with the tag will be
	removed.

FUNCTION


NAME

        reduce_verb - Allows external reduction of verb data.

SYNTAX

	mixed *reduce_verb(string verb, mixed *verbdata, object *who,
			   string *adverb, string mess, string *body,
			   string preposition)

DESCRIPTION

	When you specify verbdata for a verb as an object or a file
	name, reduce_verb will be called in that object. This is a
	way for you to have complete control of a feeling, if the 
	normal types are not sufficient.

	The reduce_verb in the remote object should have the same
	arguments as the lfun in the soul, apart from the verbdata,
	which is skipped.

	The returned array should have the format:
	  ({ object *who,    //the targets
	     string text_1,  //message for the performer
	     string text_2,  //message for the targets
	     string text_3,  //message for the audience
	     string text_4,  //message for the performer (meta)
	     string text_5,  //message for the targets   (meta)
	     string text_6,  //message for the audience  (meta)
	  })
The texts may still contain the target modifiers; \nWHO, \nPOSS, \nTHEIR, \nOBJ, \nSUBJ and \nIS, since they will be replaced later.

NOTE

	Always make sure that your external reduce_verb works
	even if there is no this_player(). The reason for this
	is that the creation of help files uses the reduce_verb
	without a this_player().

EXAMPLE

	// A simple feeling that uses your wielded weapon in it.
	#define SIMP 0
	soul -> add_verb( ([ "wbonk":this_object() ]) );
	...
	reduce_verb(verb, who, adverb, mess, body, prep) {
	  mixed weapon;
	  if (verb == "wbonk") {
	    if(!this_interactive()
	       || !(weapon = this_interactive() -> query_wielded());
	     weapon = "hand";
	    else
	      weapon = weapon[0] -> query_name() || "hand";
	    // Now let the soul handle the feeling in the normal
	    // fashion by calling back to the soul with a verbdata array.
	    return previous_object() -> reduce_verb(
	       verb,
	       ({ 0, 0, " bonk$ \nWHO \nHOW \nWHERE with \nYOUR " +
		        weapon }),
	       who, adverb, mess, body, prep);
	  }
	}