From 36768f40bc885b19799226d83eea313c12a555e7 Mon Sep 17 00:00:00 2001 From: Rumble Date: Sat, 14 Jun 2008 02:29:33 +0000 Subject: [PATCH] [Jun 14 2008] - Rumble Made immortals immune to blinding. Fixed bug in qedit where quest completion would try to load an object with vnum NOTHING. (thanks Jamdog) Fixed log when builder tries to edit a zone without permission. --- changelog | 4 ++++ src/act.informative.c | 10 +++++----- src/magic.c | 2 +- src/oasis.c | 2 +- src/quest.c | 14 +++++++------- src/utils.h | 3 ++- 6 files changed, 20 insertions(+), 15 deletions(-) diff --git a/changelog b/changelog index fb4a875..80ad974 100644 --- a/changelog +++ b/changelog @@ -3,6 +3,10 @@ help, find any bugs, or have ideas for improvement please stop by TBA at telnet://tbamud.com:9091 or email rumble@tbamud.com --Rumble tbaMUD 3.56 +[Jun 14 2008] - Rumble + Made immortals immune to blinding. + Fixed bug in qedit where quest completion would try to load an object with vnum NOTHING. (thanks Jamdog) + Fixed log when builder tries to edit a zone without permission. [Jun 12 2008] - Rumble Fixed toggle quest to toggle correctly. Fixed bug in dg find_replacement to call text_processed at the beginning, regardless of whether something matching the variable is found or not. (thanks Laoris) diff --git a/src/act.informative.c b/src/act.informative.c index 6d3f407..4016221 100644 --- a/src/act.informative.c +++ b/src/act.informative.c @@ -321,7 +321,7 @@ static void list_one_char(struct char_data *i, struct char_data *ch) if (AFF_FLAGGED(i, AFF_SANCTUARY)) act("...$e glows with a bright light!", FALSE, i, 0, ch, TO_VICT); - if (AFF_FLAGGED(i, AFF_BLIND)) + if (AFF_FLAGGED(i, AFF_BLIND) && GET_LEVEL(i) < LVL_IMMORT) act("...$e is groping around blindly!", FALSE, i, 0, ch, TO_VICT); return; @@ -426,7 +426,7 @@ ACMD(do_exits) { int door, len = 0; - if (AFF_FLAGGED(ch, AFF_BLIND)) { + if (AFF_FLAGGED(ch, AFF_BLIND) && GET_LEVEL(ch) < LVL_IMMORT) { send_to_char(ch, "You can't see a damned thing, you're blind!\r\n"); return; } @@ -468,7 +468,7 @@ void look_at_room(struct char_data *ch, int ignore_brief) if (IS_DARK(IN_ROOM(ch)) && !CAN_SEE_IN_DARK(ch)) { send_to_char(ch, "It is pitch black...\r\n"); return; - } else if (AFF_FLAGGED(ch, AFF_BLIND)) { + } else if (AFF_FLAGGED(ch, AFF_BLIND) && GET_LEVEL(ch) < LVL_IMMORT) { send_to_char(ch, "You see nothing but infinite darkness...\r\n"); return; } @@ -690,7 +690,7 @@ ACMD(do_look) if (GET_POS(ch) < POS_SLEEPING) send_to_char(ch, "You can't see anything but stars!\r\n"); - else if (AFF_FLAGGED(ch, AFF_BLIND)) + else if (AFF_FLAGGED(ch, AFF_BLIND) && GET_LEVEL(ch) < LVL_IMMORT) send_to_char(ch, "You can't see a damned thing, you're blind!\r\n"); else if (IS_DARK(IN_ROOM(ch)) && !CAN_SEE_IN_DARK(ch)) { send_to_char(ch, "It is pitch black...\r\n"); @@ -866,7 +866,7 @@ ACMD(do_score) if (GET_COND(ch, THIRST) == 0) send_to_char(ch, "You are thirsty.\r\n"); - if (AFF_FLAGGED(ch, AFF_BLIND)) + if (AFF_FLAGGED(ch, AFF_BLIND) && GET_LEVEL(ch) < LVL_IMMORT) send_to_char(ch, "You have been blinded!\r\n"); if (AFF_FLAGGED(ch, AFF_INVISIBLE)) diff --git a/src/magic.c b/src/magic.c index 54e1860..896da22 100644 --- a/src/magic.c +++ b/src/magic.c @@ -353,7 +353,7 @@ void mag_affects(int level, struct char_data *ch, struct char_data *victim, break; case SPELL_BLINDNESS: - if (MOB_FLAGGED(victim,MOB_NOBLIND) || mag_savingthrow(victim, savetype, 0)) { + if (MOB_FLAGGED(victim, MOB_NOBLIND) || GET_LEVEL(victim) >= LVL_IMMORT || mag_savingthrow(victim, savetype, 0)) { send_to_char(ch, "You fail.\r\n"); return; } diff --git a/src/oasis.c b/src/oasis.c index 56c6310..207a879 100644 --- a/src/oasis.c +++ b/src/oasis.c @@ -294,7 +294,7 @@ void send_cannot_edit(struct char_data *ch, zone_vnum zone) send_to_char(ch, "You do not have permission to edit zone %d. Try zone %d.\r\n", zone, GET_OLC_ZONE(ch)); sprintf(buf, "OLC: %s tried to edit zone %d (allowed zone %d).", GET_NAME(ch), zone, GET_OLC_ZONE(ch)); } else { - send_to_char(ch, "You do not have permission to edit zone %d.\r\n", GET_OLC_ZONE(ch)); + send_to_char(ch, "You do not have permission to edit zone %d.\r\n", zone); sprintf(buf, "OLC: %s tried to edit zone %d.", GET_NAME(ch), zone); } mudlog(BRF, LVL_IMPL, TRUE, buf); diff --git a/src/quest.c b/src/quest.c index be55794..e2c54a0 100644 --- a/src/quest.c +++ b/src/quest.c @@ -305,14 +305,14 @@ void generic_complete_quest(struct char_data *ch) "You have been awarded %d experience points for your service.\r\n", QST_EXP(rnum)); } - if (QST_OBJ(rnum)) { - if (real_object(QST_OBJ(rnum))) { - if ((new_obj = create_obj()) != NULL) { - new_obj = read_object((QST_OBJ(rnum)),VIRTUAL); - obj_to_char(new_obj, ch); - send_to_char(ch, - "You have been presented with %s%s for your service.\r\n", + if (QST_OBJ(rnum) && QST_OBJ(rnum) != NOTHING) { + if (real_object(QST_OBJ(rnum)) != NOTHING) { + if ((new_obj = create_obj()) != NULL) { + if ((new_obj = read_object((QST_OBJ(rnum)),VIRTUAL)) != NULL) { + obj_to_char(new_obj, ch); + send_to_char(ch, "You have been presented with %s%s for your service.\r\n", GET_OBJ_SHORT(new_obj), CCNRM(ch, C_NRM)); + } } } } diff --git a/src/utils.h b/src/utils.h index 4963fc4..2b9fcb9 100644 --- a/src/utils.h +++ b/src/utils.h @@ -671,7 +671,8 @@ void char_from_furniture(struct char_data *ch); /** Defines if there is enough light for sub to see in. */ #define LIGHT_OK(sub) (!AFF_FLAGGED(sub, AFF_BLIND) && \ - (IS_LIGHT(IN_ROOM(sub)) || AFF_FLAGGED((sub), AFF_INFRAVISION))) + (IS_LIGHT(IN_ROOM(sub)) || AFF_FLAGGED((sub), AFF_INFRAVISION) || \ + GET_LEVEL(sub) >= LVL_IMMORT)) /** Defines if sub character can see the invisible obj character. */ #define INVIS_OK(sub, obj) \