/* * skull.c * * Handles the skull code. * When a mobile or player dies, there is a chance * that the killer may recive their skull. A skull * is a trophy of sorts, usable in a varity of ways. */ #include <sys/types.h> #include <stdio.h> #include <time.h> #include "merc.h" #include "tables.h" OBJ_DATA * create_skull(char * name) { OBJ_DATA * obj; char buf[MSL]; obj = create_object (get_obj_index (70), 0); sprintf (buf, obj->short_descr, name); free_string (obj->short_descr); obj->short_descr = str_dup (buf); sprintf (buf, obj->description, name); free_string (obj->description); obj->description = str_dup (buf); obj->item_type = ITEM_SKULL; return obj; } void skull_heal(CHAR_DATA * ch, CHAR_DATA * mob) { OBJ_DATA * obj; char buf[MSL]; if ((obj = get_obj_carry (ch, "skull bleached", ch)) == NULL) { act ("$n tells you 'You do not have a skull!'.", mob, NULL, ch, TO_VICT); ch->reply = mob; return; } extract_obj(obj); sprintf(buf, "\n%s takes %s and performs a sacrifice...\n\n", mob->short_descr, obj->short_descr); stc(buf, ch); stc("\n\n{RYou feel fully refreshed!{x\n\n", ch); ch->hit = ch->max_hit; ch->mana = ch->max_mana; ch->move = ch->max_move; return; }