more ^X (trunk only)
The characteristics display checked for cursed rings of sustain ability but neglected to check for uncursed ones locked in place by cursed gloves or weapon. And the half-hearted attempt to check for future items conferring Fixed_abil couldn't handle an uncursed thing covered by something cursed either, so just get rid of it.
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
/* SCCS Id: @(#)cmd.c 3.5 2008/02/14 */
|
/* SCCS Id: @(#)cmd.c 3.5 2008/02/12 */
|
||||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||||
/* NetHack may be freely redistributed. See license for details. */
|
/* NetHack may be freely redistributed. See license for details. */
|
||||||
|
|
||||||
@@ -1277,17 +1277,8 @@ int mode, final, attrindx;
|
|||||||
if (Upolyd) {
|
if (Upolyd) {
|
||||||
hide_innate_value = TRUE;
|
hide_innate_value = TRUE;
|
||||||
} else if (Fixed_abil) {
|
} else if (Fixed_abil) {
|
||||||
struct obj *o;
|
if (stuck_ring(uleft, RIN_SUSTAIN_ABILITY) ||
|
||||||
|
stuck_ring(uright, RIN_SUSTAIN_ABILITY))
|
||||||
if ((uleft && uleft->otyp == RIN_SUSTAIN_ABILITY && uleft->cursed) ||
|
|
||||||
(uright && uright->otyp == RIN_SUSTAIN_ABILITY && uright->cursed) ||
|
|
||||||
/* suboptimal--won't work if someone adds a new item
|
|
||||||
conferring fixed abilities and hero wears both it and
|
|
||||||
non-cursed ring of same and what_gives() happens to
|
|
||||||
find the ring first--but perhaps better than ignoring
|
|
||||||
the possibility of adding such an item at all */
|
|
||||||
((o = what_gives(&Fixed_abil)) != 0 &&
|
|
||||||
(o->owornmask & (W_ARMOR|W_AMUL|W_TOOL)) && o->cursed))
|
|
||||||
hide_innate_value = TRUE;
|
hide_innate_value = TRUE;
|
||||||
}
|
}
|
||||||
switch (attrindx) {
|
switch (attrindx) {
|
||||||
@@ -1311,6 +1302,7 @@ int mode, final, attrindx;
|
|||||||
break;
|
break;
|
||||||
default: return; /* impossible */
|
default: return; /* impossible */
|
||||||
};
|
};
|
||||||
|
/* note: final disclosure includes MAGICENLIGHTENTMENT */
|
||||||
if ((mode & MAGICENLIGHTENMENT) && !Upolyd) hide_innate_value = FALSE;
|
if ((mode & MAGICENLIGHTENMENT) && !Upolyd) hide_innate_value = FALSE;
|
||||||
|
|
||||||
acurrent = ACURR(attrindx);
|
acurrent = ACURR(attrindx);
|
||||||
|
|||||||
Reference in New Issue
Block a user