wounded legs fixes

Document 'HWounded_legs' vs 'EWounded_legs'; they aren't used the way
other properties use their intrinsic and extrinsic values.  And they
switch from hero to steed when riding.  (Can't start riding when
hero's legs are wounded and the steed's legs magically heal when hero
dismounts, so existing wounds never transfer from one to the other.)

Having one leg become injured when the other already was would cure
the other leg but keep the longer of their two timeouts for the new
injury.  Eliminate that mystery cure.  Since their timeouts aren't
tracked separately, the best that can be done is to make both legs
eventually recover at the same time.

Make ^X report which leg is the wounded one when only one of them is.
(It already implicitly reports the both-legs case by using plural.)

When zapping a wand of probing downward while riding, include wounded
leg feedback for the steed.

Simplify wounded leg feedback when probing self a little bit.

Make drinking blessed potions of full healing cure wounded legs for
hero when not mounted or for steed when mounted.  (The latter is a
bit strange--hero drinks potion, steed gets affected--but it's magic.)

Make drinking uncursed potions of full healing or blessed potions of
extra healing cure wounded legs for hero (but not steed; the magic
either isn't that strong or maybe not that reliable...).
This commit is contained in:
PatR
2022-01-03 13:44:05 -08:00
parent dbd1f7a33b
commit 292a4f9d03
5 changed files with 70 additions and 19 deletions

View File

@@ -1074,6 +1074,10 @@ peffect_extra_healing(struct obj *otmp)
(void) make_hallucinated(0L, TRUE, 0L);
exercise(A_CON, TRUE);
exercise(A_STR, TRUE);
/* blessed potion also heals wounded legs unless riding (where leg
wounds apply to the steed rather than to the hero) */
if (Wounded_legs && (otmp->blessed && !u.usteed))
heal_legs(0);
}
static void
@@ -1091,6 +1095,10 @@ peffect_full_healing(struct obj *otmp)
(void) make_hallucinated(0L, TRUE, 0L);
exercise(A_STR, TRUE);
exercise(A_CON, TRUE);
/* blessed potion heals wounded legs even when riding (so heals steed's
legs--it's magic); uncursed potion heals hero's legs unless riding */
if (Wounded_legs && (otmp->blessed || (!otmp->cursed && !u.usteed)))
heal_legs(0);
}
static void