A minor patch to get / take One thing that has always annoyed me is that if a builder adds lots of room extra descriptions, to add colour and life to their zones, you have the strange situation where you can look at something, but get an illogical message if you try to take it. See the situation below. -------------------------------------------------------------------------- Inside The West Gate Of Midgaard You are by two small towers that have been built into the city wall and connected with a footbridge across the heavy wooden gate. Main Street leads east and Wall Road leads south from here. [ Exits: e s w ] A cityguard is here, guarding the gate. > l wall It is built from large grey rocks that have been fastened to each other with some kind of mortar. It is far too high to climb. > take wall You don't see a wall here. > ----------------------------------------------------------------------------- Thsi is because "look_at_target" (in act.informative.c) checks to see if the thing you are looking at is an extra description associated with the room, and if so, displays that. However, when you try to get that item, "get_from_room" doesn't make a similar check. Hence the "you don't see" message - when you can clearly see the item. What this patch does is to add that check into "get_from_room", and display a more sensible message. ------------------------------------------------------------------------------- Inside The West Gate Of Midgaard You are by two small towers that have been built into the city wall and connected with a footbridge across the heavy wooden gate. Main Street leads east and Wall Road leads south from here. [ Exits: e s w ] A cityguard is here, guarding the gate. > l wall It is built from large grey rocks that have been fastened to each other with some kind of mortar. It is far too high to climb. > take wall You can't take a wall. > --------------------------------------------------------------------------------- The patch is pretty simple, and involves adding one external function declaration to act.item.c, and the simple if test in get_from_room. --- circle-3.1-stock/src/act.item.c 2002-09-25 18:44:45.000000000 -0500 +++ circle-3.1-test/src/act.item.c 2003-06-01 12:11:14.000000000 -0500 @@ -28,6 +28,9 @@ extern room_rnum donation_room_2; /* un extern room_rnum donation_room_3; /* uncomment if needed! */ #endif +/* extern functions */ +char *find_exdesc(char *word, struct extra_descr_data *list); + /* local functions */ int can_take_obj(struct char_data *ch, struct obj_data *obj); void get_check_money(struct char_data *ch, struct obj_data *obj); @@ -291,6 +294,12 @@ void get_from_room(struct char_data *ch, struct obj_data *obj, *next_obj; int dotmode, found = 0; + /* Are they trying to take something in a room extra description? */ + if (find_exdesc(arg, world[IN_ROOM(ch)].ex_description) != NULL) { + send_to_char(ch, "You can't take %s %s.\r\n", AN(arg), arg); + return; + } + dotmode = find_all_dots(arg); if (dotmode == FIND_INDIV) {