Monster with Skills

// Petrarch // A monster who uses skills, set skills // Also reacts to players // Also has money and items on him. #include <std.h> inherit MONSTER; void create() { ::create(); set_name("gnome"); set_short("a gnome is here exploring the forest"); set_long("The gnome appears to be exploring the forest. He could be " "searching for something the way he is carrying about."); set_id(({"gnome", "explorer"})); set_level(10); set_race("gnome"); set_body_type("human"); set_gender("male"); add_money("gold", 100); // Give him some money add_money("platinum", 5); set_skill("attack", 60); // sets his attack skill to 60 set_stats("stregnth", 25); // sets his strength to 25 set_spell_chance(20); // NOTE: you still use set_spells for either set_spells(({"whirl", "bash", "slaughter"})); // spells or skills new("/realms/petrarch/forest/armour/vest")->move(this_object()); command("wear vest"); if(random(2)) { new("/realms/petrarch/forest/weapons/sword")->move(this_object()); command("wield sword"); } } void catch_tell(string str) { string a, b; if(!str) return; str=lower_case(strip_colours(str)); if(sscanf(str, "%s says: %s", a, b)!=2) return; if(sscanf(b, "%squest%s", a, str)==2) { force_me("say I have a quest for you. Will you find my key?"); return; } if(sscanf(b, "%skey%s", a, str)==2) { force_me("say My wooden key, I lost it somewhere."); return; } if(sscanf(b, "%slost%s", a, str)==2) { force_me("say Yup, lost, my key is lost. I cannot get into my house."); return; } }