new status conditions
Several conditions result in stale data on the status line when starting or stopping because things which didn't used to affect it haven't been setting context.botl to force an update. This wasn't systematic; there are bound to be lots more.
This commit is contained in:
20
src/do.c
20
src/do.c
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 do.c $NHDT-Date: 1581322660 2020/02/10 08:17:40 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.224 $ */
|
||||
/* NetHack 3.6 do.c $NHDT-Date: 1581810044 2020/02/15 23:40:44 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.226 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Derek S. Ray, 2015. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -2011,8 +2011,8 @@ dowipe()
|
||||
|
||||
void
|
||||
set_wounded_legs(side, timex)
|
||||
register long side;
|
||||
register int timex;
|
||||
long side;
|
||||
int timex;
|
||||
{
|
||||
/* KMH -- STEED
|
||||
* If you are riding, your steed gets the wounded legs instead.
|
||||
@@ -2020,13 +2020,12 @@ register int timex;
|
||||
* Caller is also responsible for adjusting messages.
|
||||
*/
|
||||
|
||||
if (!Wounded_legs) {
|
||||
g.context.botl = 1;
|
||||
if (!Wounded_legs)
|
||||
ATEMP(A_DEX)--;
|
||||
g.context.botl = 1;
|
||||
}
|
||||
|
||||
if (!Wounded_legs || (HWounded_legs & TIMEOUT))
|
||||
HWounded_legs = timex;
|
||||
if (!Wounded_legs || (HWounded_legs & TIMEOUT) < timex)
|
||||
set_itimeout(&HWounded_legs, (long) timex);
|
||||
EWounded_legs = side;
|
||||
(void) encumber_msg();
|
||||
}
|
||||
@@ -2036,10 +2035,9 @@ heal_legs(how)
|
||||
int how; /* 0: ordinary, 1: dismounting steed, 2: limbs turn to stone */
|
||||
{
|
||||
if (Wounded_legs) {
|
||||
if (ATEMP(A_DEX) < 0) {
|
||||
g.context.botl = 1;
|
||||
if (ATEMP(A_DEX) < 0)
|
||||
ATEMP(A_DEX)++;
|
||||
g.context.botl = 1;
|
||||
}
|
||||
|
||||
/* when mounted, wounded legs applies to the steed;
|
||||
during petrification countdown, "your limbs turn to stone"
|
||||
|
||||
Reference in New Issue
Block a user