[Oct 08 2009] - Rumble

Fixed do_purge to allow targetting of multiple objects of the same name. i.e.
2.knife. (thanks Drefs)
[Oct 07 2009] - Rumble
  Added CAN_SEE_IN_DARK and AFF_BLIND checks in do_automap. (thanks Frenze)
[Oct 06 2009] - Rumble
  Fixed do_cast to allow targetting of multiple objects of the same name. i.e. 2
.knife. (thanks Drefs)
[Oct 04 2009] - Rumble
  Fixed a bug on filling unlimited containers where it doesn't update weight. (t
hanks Drefs)
[Oct 02 2009] - Rumble
  Fixed buildwalk so it does not require the first room to exist. (thanks Zizaza
t)
This commit is contained in:
Rumble 2009-10-08 00:42:46 +00:00
parent 5e3caf42ff
commit 9f5b893ec5
6 changed files with 35 additions and 12 deletions

View file

@ -35,6 +35,17 @@ export (QQ's a zone into a tarball)
Xlist (mlist, olist, rlist, zlist, slist, tlist, qlist) Xlist (mlist, olist, rlist, zlist, slist, tlist, qlist)
(lots of major bugfixes too) (lots of major bugfixes too)
@ @
tbaMUD 3.61
[Oct 08 2009] - Rumble
Fixed do_purge to allow targetting of multiple objects of the same name. i.e. 2.knife. (thanks Drefs)
[Oct 07 2009] - Rumble
Added CAN_SEE_IN_DARK and AFF_BLIND checks in do_automap. (thanks Frenze)
[Oct 06 2009] - Rumble
Fixed do_cast to allow targetting of multiple objects of the same name. i.e. 2.knife. (thanks Drefs)
[Oct 04 2009] - Rumble
Fixed a bug on filling unlimited containers where it doesn't update weight. (thanks Drefs)
[Oct 02 2009] - Rumble
Fixed buildwalk so it does not require the first room to exist. (thanks Zizazat)
tbaMUD 3.6 tbaMUD 3.6
[Aug 29 2009] - Rumble [Aug 29 2009] - Rumble
Removed unused prototype log_death_trap in utils.h (thanks Xiuhtecuhtli) Removed unused prototype log_death_trap in utils.h (thanks Xiuhtecuhtli)

View file

@ -1145,9 +1145,10 @@ ACMD(do_pour)
GET_OBJ_VAL(from_obj, 3) = 0; GET_OBJ_VAL(from_obj, 3) = 0;
} }
} }
else else {
GET_OBJ_VAL(to_obj, 1) = GET_OBJ_VAL(to_obj, 0); GET_OBJ_VAL(to_obj, 1) = GET_OBJ_VAL(to_obj, 0);
amount = GET_OBJ_VAL(to_obj, 0);
}
/* Poisoned? */ /* Poisoned? */
GET_OBJ_VAL(to_obj, 3) = (GET_OBJ_VAL(to_obj, 3) || GET_OBJ_VAL(from_obj, 3)) GET_OBJ_VAL(to_obj, 3) = (GET_OBJ_VAL(to_obj, 3) || GET_OBJ_VAL(from_obj, 3))
; ;

View file

@ -1394,15 +1394,18 @@ ACMD(do_vstat)
ACMD(do_purge) ACMD(do_purge)
{ {
char buf[MAX_INPUT_LENGTH]; char buf[MAX_INPUT_LENGTH];
char *t;
struct char_data *vict; struct char_data *vict;
struct obj_data *obj; struct obj_data *obj;
int number;
one_argument(argument, buf); one_argument(argument, buf);
/* argument supplied. destroy single object or char */ /* argument supplied. destroy single object or char */
if (*buf) { if (*buf) {
if ((vict = get_char_vis(ch, buf, NULL, FIND_CHAR_ROOM)) != NULL) { t = buf;
if (!IS_NPC(vict) && (GET_LEVEL(ch) <= GET_LEVEL(vict))) { number = get_number(&t);
if ((vict = get_char_vis(ch, buf, &number, FIND_CHAR_ROOM)) != NULL) { if (!IS_NPC(vict) && (GET_LEVEL(ch) <= GET_LEVEL(vict))) {
send_to_char(ch, "You can't purge %s!\r\n", HMHR(vict)); send_to_char(ch, "You can't purge %s!\r\n", HMHR(vict));
return; return;
} }
@ -1417,7 +1420,7 @@ ACMD(do_purge)
} }
} }
extract_char(vict); extract_char(vict);
} else if ((obj = get_obj_in_list_vis(ch, buf, NULL, world[IN_ROOM(ch)].contents)) != NULL) { } else if ((obj = get_obj_in_list_vis(ch, buf, &number, world[IN_ROOM(ch)].contents)) != NULL) {
act("$n destroys $p.", FALSE, ch, obj, 0, TO_ROOM); act("$n destroys $p.", FALSE, ch, obj, 0, TO_ROOM);
extract_obj(obj); extract_obj(obj);
} else { } else {

View file

@ -535,6 +535,13 @@ ACMD(do_map) {
send_to_char(ch, "Sorry, the map is disabled!\r\n"); send_to_char(ch, "Sorry, the map is disabled!\r\n");
return; return;
} }
if (IS_DARK(IN_ROOM(ch)) && !CAN_SEE_IN_DARK(ch)) {
send_to_char(ch, "It is too dark to see the map.\r\n");
return;
} else if (AFF_FLAGGED(ch, AFF_BLIND) && GET_LEVEL(ch) < LVL_IMMORT) {
send_to_char(ch, "You can't see the map while blind!\r\n");
return;
}
perform_map(ch, argument, ROOM_FLAGGED(IN_ROOM(ch), ROOM_WORLDMAP) ? 1 : 0 ); perform_map(ch, argument, ROOM_FLAGGED(IN_ROOM(ch), ROOM_WORLDMAP) ? 1 : 0 );
} }

View file

@ -295,7 +295,7 @@ static room_vnum redit_find_new_vnum(zone_rnum zone)
room_rnum rnum = real_room(vnum); room_rnum rnum = real_room(vnum);
if (rnum == NOWHERE) if (rnum == NOWHERE)
return NOWHERE; return vnum;
for(;;) { for(;;) {
if (vnum > zone_table[zone].top) if (vnum > zone_table[zone].top)

View file

@ -489,7 +489,7 @@ ACMD(do_cast)
struct char_data *tch = NULL; struct char_data *tch = NULL;
struct obj_data *tobj = NULL; struct obj_data *tobj = NULL;
char *s, *t; char *s, *t;
int mana, spellnum, i, target = 0; int number, mana, spellnum, i, target = 0;
if (IS_NPC(ch)) if (IS_NPC(ch))
return; return;
@ -539,16 +539,17 @@ ACMD(do_cast)
if (IS_SET(SINFO.targets, TAR_IGNORE)) { if (IS_SET(SINFO.targets, TAR_IGNORE)) {
target = TRUE; target = TRUE;
} else if (t != NULL && *t) { } else if (t != NULL && *t) {
number = get_number(&t);
if (!target && (IS_SET(SINFO.targets, TAR_CHAR_ROOM))) { if (!target && (IS_SET(SINFO.targets, TAR_CHAR_ROOM))) {
if ((tch = get_char_vis(ch, t, NULL, FIND_CHAR_ROOM)) != NULL) if ((tch = get_char_vis(ch, t, &number, FIND_CHAR_ROOM)) != NULL)
target = TRUE; target = TRUE;
} }
if (!target && IS_SET(SINFO.targets, TAR_CHAR_WORLD)) if (!target && IS_SET(SINFO.targets, TAR_CHAR_WORLD))
if ((tch = get_char_vis(ch, t, NULL, FIND_CHAR_WORLD)) != NULL) if ((tch = get_char_vis(ch, t, &number, FIND_CHAR_WORLD)) != NULL)
target = TRUE; target = TRUE;
if (!target && IS_SET(SINFO.targets, TAR_OBJ_INV)) if (!target && IS_SET(SINFO.targets, TAR_OBJ_INV))
if ((tobj = get_obj_in_list_vis(ch, t, NULL, ch->carrying)) != NULL) if ((tobj = get_obj_in_list_vis(ch, t, &number, ch->carrying)) != NULL)
target = TRUE; target = TRUE;
if (!target && IS_SET(SINFO.targets, TAR_OBJ_EQUIP)) { if (!target && IS_SET(SINFO.targets, TAR_OBJ_EQUIP)) {
@ -559,11 +560,11 @@ ACMD(do_cast)
} }
} }
if (!target && IS_SET(SINFO.targets, TAR_OBJ_ROOM)) if (!target && IS_SET(SINFO.targets, TAR_OBJ_ROOM))
if ((tobj = get_obj_in_list_vis(ch, t, NULL, world[IN_ROOM(ch)].contents)) != NULL) if ((tobj = get_obj_in_list_vis(ch, t, &number, world[IN_ROOM(ch)].contents)) != NULL)
target = TRUE; target = TRUE;
if (!target && IS_SET(SINFO.targets, TAR_OBJ_WORLD)) if (!target && IS_SET(SINFO.targets, TAR_OBJ_WORLD))
if ((tobj = get_obj_vis(ch, t, NULL)) != NULL) if ((tobj = get_obj_vis(ch, t, &number)) != NULL)
target = TRUE; target = TRUE;
} else { /* if target string is empty */ } else { /* if target string is empty */