[ Package Index | Mudlib Index | Effect Index ]

File /std/race.c

This is called off of the monster to set up a race and profession... Race should be first then profession..

Written by Pinkfish

Started Sometime in 1991


Inherits

This class inherits the following classes /std/basic/print_object.c

Includes

This class includes the following files /include/race.h

Method index

 o monster_heart_beat(string, string, mixed, mixed)
This method is called from inside the npc to do the heartbeat on the guild and race objects.
 o query_guild_path(string)
This method returns the path associated with the specified guild.
 o query_guilds()
This method returns all the current guilds in the race object.
 o query_race_path(string)
This method returns the path associated with the specified race.
 o query_races()
This method returns all the current races in the race object.
 o query_valid_race(string)
This method checks to see if the specified race is valid or not.
 o set_level(int, string, string)
This method sets the level of the npc with the specified attributes.

Public Functions

These are functions that everyone can access.

.
 * monster_heart_beat
void monster_heart_beat(string race,
                        string guild,
                        mixed race_ob,
                        mixed guild_ob)
This method is called from inside the npc to do the heartbeat on the guild and race objects.

Parameters:
race - the race to do a heart beat on
guild - the guild to do a heart beat on
race_ob - the object to use for the race
guild_ob - the object to use for the guild
 * query_guild_path
string query_guild_path(string guild_name)
This method returns the path associated with the specified guild.

Parameters:
guild_name - the name of the guild
Returns:
the path of the guild
 * query_guilds
mapping query_guilds()
This method returns all the current guilds in the race object. It is a mapping with matches between the name of the guild and guild object.

Returns:
the race mapping
 * query_race_path
string query_race_path(string race_name)
This method returns the path associated with the specified race.

Parameters:
race_name - the name of the race
Returns:
the path of the race
 * query_races
mapping query_races()
This method returns all the current races in the race object. It is a mapping with matches between the name of the race and race object.

Returns:
the race mapping
 * query_valid_race
int query_valid_race(string race)
This method checks to see if the specified race is valid or not.

Parameters:
race - the race to check for validity
Returns:
1 if it exists, 0 if it does not
 * set_level
void set_level(int lvl,
               string race,
               string guild)
This method sets the level of the npc with the specified attributes.

Parameters:
lvl - the level to set the npc at
race - the race to set the npc with
guild - the guild to set the npc with

Discworld MUD's distribution world wide web pages.
brought to you by
Cut Me Own Throat Dibbler's Sensational Sausages; buy one while they are hot.
File last modified: Sat, 06 Sep 2003 04:05:30 GMT

Lost? Try Discworld's home page.