I have tested the following special procedure and it
seems to hold up against everything I could think of
but does anyone see any possibles problems with it:
It is an object spec proc that should transfer a player
into another room if they type 'enter cabinet'.
I have the object defined as type other and the only
name it can be referred to as is 'cabinet'.
Here is the procedure:
SPECIAL(wine_cabinet)
{
struct obj_data *obj = (struct obj_data *) me;
struct obj_data *wine;
char obj_name[MAX_STRING_LENGTH];
if(!CMD_IS("enter")) {
send_to_char("DEBUG 1\r\n", ch);
return FALSE;
}
one_argument(argument, obj_name);
if (!(wine = get_obj_in_list_vis(ch, obj_name,
world[ch->in_room].contents))) {
send_to_char("DEBUG 2\r\n", ch);
return FALSE;
}
if (wine != obj) {
send_to_char("DEBUG 4\r\n", ch);
return FALSE;
}
if(GET_CLASS(ch) != CLASS_THIEF) {
send_to_char("A hooded figure pushes you back out of the cabinet.\r\n",
ch);
return FALSE;
}
act("$n slips into the wine cabinet and disappears.", TRUE, ch, 0, FALSE,
TO_ROOM);
char_from_room(ch);
char_to_room(ch, real_room(2612));
look_at_room(ch, 0);
return TRUE;
}
Thanks in advance,
Chuck
+------------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
| http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
+------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST