monk's to-hit penalty for wearing a suit
If hero is a monk who is wearing a suit, have ^X mention the to-hit penalty for that in the status section even though it isn't a normal status line item. Combat feedback makes it annoyingly obvious, but player might forget if MSGTYPE=hide is used to suppress the "Your armor is rather cumbersome..." message.
This commit is contained in:
@@ -391,6 +391,7 @@ for !fixinv option where inventory letters normally don't stick, try to put
|
||||
thrown from; only works if it does return and is successfully caught
|
||||
wizard mode #wizborn command
|
||||
include more skill information in ^X output when dual-wielding
|
||||
include monk's to-hit penalty for worn suit in the status section of ^X output
|
||||
item-using monsters will zap wand of undead turning at corpse-wielding hero
|
||||
when the corpse is harmful
|
||||
boiling a pool or fountain now creates a temporary cloud of steam
|
||||
|
||||
@@ -238,6 +238,7 @@ struct instance_flags {
|
||||
* disable to avoid excessive noise when using
|
||||
* a screen reader (use ^X to review status) */
|
||||
boolean toptenwin; /* ending list in window instead of stdout */
|
||||
boolean tux_penalty; /* True iff hero is a monk and wearing a suit */
|
||||
boolean use_background_glyph; /* use background glyph when appropriate */
|
||||
boolean use_menu_color; /* use color in menus; only if wc_color */
|
||||
#ifdef STATUS_HILITES
|
||||
|
||||
@@ -1018,6 +1018,15 @@ int final;
|
||||
}
|
||||
/* current weapon(s) and corresponding skill level(s) */
|
||||
weapon_insight(final);
|
||||
/* unlike ring of increase accuracy's effect, the monk's suit penalty
|
||||
is too blatant to be restricted to magical enlightenment */
|
||||
if (iflags.tux_penalty && !Upolyd) {
|
||||
(void) enlght_combatinc("to hit", -g.urole.spelarmr, final, buf);
|
||||
/* if from_what() ever gets extended from wizard mode to normal
|
||||
play, it could be adapted to handled this */
|
||||
Sprintf(eos(buf), " due to your %s", suit_simple_name(uarm));
|
||||
you_have(buf, "");
|
||||
}
|
||||
/* report 'nudity' */
|
||||
if (!uarm && !uarmu && !uarmc && !uarms && !uarmg && !uarmf && !uarmh) {
|
||||
if (u.uroleplay.nudist)
|
||||
@@ -1467,8 +1476,13 @@ int final;
|
||||
enl_msg("You regenerate", "", "d", "", from_what(REGENERATION));
|
||||
if (Slow_digestion)
|
||||
you_have("slower digestion", from_what(SLOW_DIGESTION));
|
||||
if (u.uhitinc)
|
||||
you_have(enlght_combatinc("to hit", u.uhitinc, final, buf), "");
|
||||
if (u.uhitinc) {
|
||||
(void) enlght_combatinc("to hit", u.uhitinc, final, buf);
|
||||
if (iflags.tux_penalty && !Upolyd)
|
||||
Sprintf(eos(buf), " %s your suit penalty",
|
||||
(u.uhitinc < 0) ? "increasing" : "offsetting");
|
||||
you_have(buf, "");
|
||||
}
|
||||
if (u.udaminc)
|
||||
you_have(enlght_combatinc("damage", u.udaminc, final, buf), "");
|
||||
if (u.uspellprot || Protection) {
|
||||
|
||||
11
src/worn.c
11
src/worn.c
@@ -57,9 +57,7 @@ long mask;
|
||||
uskin = obj;
|
||||
/* assert( !uarm ); */
|
||||
} else {
|
||||
if ((mask & W_ARMOR))
|
||||
u.uroleplay.nudist = FALSE;
|
||||
for (wp = worn; wp->w_mask; wp++)
|
||||
for (wp = worn; wp->w_mask; wp++) {
|
||||
if (wp->w_mask & mask) {
|
||||
oobj = *(wp->w_obj);
|
||||
if (oobj && !(oobj->owornmask & wp->w_mask))
|
||||
@@ -105,6 +103,11 @@ long mask;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (obj && (obj->owornmask & W_ARMOR) != 0L)
|
||||
u.uroleplay.nudist = FALSE;
|
||||
/* tux -> tuxedo -> "monkey suit" -> monk's suit */
|
||||
iflags.tux_penalty = (uarm && Role_if(PM_MONK) && g.urole.spelarmr);
|
||||
}
|
||||
update_inventory();
|
||||
}
|
||||
@@ -137,6 +140,8 @@ register struct obj *obj;
|
||||
if ((p = w_blocks(obj, wp->w_mask)) != 0)
|
||||
u.uprops[p].blocked &= ~wp->w_mask;
|
||||
}
|
||||
if (!uarm)
|
||||
iflags.tux_penalty = FALSE;
|
||||
update_inventory();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user