NAME basic_monster.c - a very basic living object INHERITS stationary.c (read stationary.doc for further details) /obj/living_functions.c SETUP FUNCTIONS set_aggressive set_race set_level set_hp set_ep set_al set_wc set_ac set_frog set_wet set_wimpy REMOTE FUNCTIONS remote_monster_init remote_monster_died remote_real_monster_died remove_prevent_attack SPECIAL PROPERTIES see_invisible monster_heal_reset QUERY FUNCTIONS query_race query_aggressive query_real_name query_npc /* always returns 1 */ query_wet query_wimpy ======================================================================= NAME set_aggressive - set how aggressive the monster is SYNTAX void set_aggressive(int delay) DESCRIPTION Set how long the monster waits before attacking someone, setting the delay to zero means you should wait forever. SEE ALSO ======================================================================= NAME set_race - set the race of the monster SYNTAX void set_race(string race) DESCRIPTION Set the value returned by query_race(). Valid values include: human, dog, horse, elf, bird, bear, dwarf, wolf, bluebird, etc. Invalid values include: priest, profezzorn, adventurer, etc. ======================================================================= NAME set_level - set the level of the monster SYNTAX void set_level(int level) DESCRIPTION Set the level of the monster, this function also sets hit points, stats and experience to aproperiate values for a monster of this level with little or no equipment. NOTA BENE Make sure to call this function _before_ calling any functions that specifics of the monster such as xp, hp, or stats. ======================================================================= NAME set_hp - set how many hit points the monster has SYNTAX void set_hp(int hp) DESCRIPTION Set how many hp the monster has, both current hp and max hp will be set. ======================================================================= NAME set_ep - set the number of experience points the monster has SYNTAX void set_ep(int experience) DESCRIPTION This function sets the number of experience points the monster has. This also controls how much experience the monster will give to whoever kills it. The player killing it will get experience/75 experience points. ======================================================================= NAME set_al - set alignment SYNTAX void set_al(int alignment) DESCRIPTION Set the alignment of the monster, valid range is -1000 to 1000. 1000 and up means saintly 200 to 1000 means good 40 to 200 means nice -40 to 40 means neutral -200 to -40 means nasty -1000 to -200 means evil below -1000 means demonic ======================================================================= NAME set_wc - set the monsters natural weapon class SYNTAX void set_wc(int wc) DESCRIPTION Set the monsters natural weapon class, see /doc/RULES/monster.r for a list of recommended values. SEE ALSO set_level ======================================================================= NAME set_ac - set the monsters natural armour class SYNTAX void set_ac(int ac) DESCRIPTION Set the monsters natural armour class, see /doc/RULES/monster.r for a list of recommended values. SEE ALSO set_level ======================================================================= NAME set_frog - turn the monster into a frog SYNTAX void set_frog() DESCRIPTION Sets the 'frog' flag in living_functions.c BUGS there is no way to turn it back to what it was without affecting the variable 'frog' directly. ======================================================================= NAME set_wet - pour water on the monster SYNTAX void set_wet(int time) DESCRIPTION Makes the monster wet for 'time' seconds. ======================================================================= NAME set_wimpy - set the wimpy percentage SYNTAX void set_wimpy(mixed wimpy) DESCRIPTION This set the wimpy percentage. The argument kan be 2 things: 1/ a percentage nr, i.e. 0-100. At 0, the monster will never run away (this is the defaulkt behaviour), and at 100 it will always run. 2/ a string on the eval() format. This string will be run through eval(), and the called function should return an integer in the range 0-100. ======================================================================= NAME remote_monster_init - init callback SYNTAX void remote_monster_init(object monster) DESCRIPTION This function is called in the 'remote object' from init() in the monster. The argument will be the monster itself. To set the remote object, do add_property("__remote",remote_object) ======================================================================= NAME remote_monster_died - monster died callback SYNTAX int remote_monster_died(object monster); DESCRIPTION This function is called in the 'remote object' after the monster has died, and a corpse has been cloned. If this function returns true, the dead monster will not be destructed. The argument is the monster itself. ======================================================================= NAME remote_real_monster_died - monster really died callback SYNTAX int remote_real_monster_died(object monster); DESCRIPTION This function is called in the 'remote object' when the monster dies, but before it clones the corpse. If this function returns true, the dead monster will not be destructed and no corpse will be cloned. ======================================================================= NAME remote_prevent_attack - aggressive control callback SYNTAX int remote_prevent_attack(object monster, object victim) DESCRIPTION Before an aggressive monster attacks it's victim, this function is called in the 'remote object'. If it returns true (that is, not zero) the victim will not be attacked. Note that this will not save the player if he chooses to attack the monster. SEE ALSO the property no_attack_switches =======================================================================
Help topics available:
basic_monster.doc | friend.doc | monster.doc | simple_monster.doc | state_monster.doc |
You are guest number 62 since March 2020.
This file was last modified: June 2000.