fix github issue #150 - delayed encumbrance msg

Fixes #150

> A very minor one, but there are some situations where your encumbrance
> level can change, but the message (such as '`Your movements are now
> unencumbered.`') isn't given until your next move or turn, even though
> the status line updates immediately.  For example, praying while weak
> and gaining a point of strength.  Picking up or dropping items or
> interacting with containers does _not_ have this problem.

This is usually fixed on a case by case basis.  Any attempt to add
blanket encumbrance check mid-turn (when updating status, for instance)
is sure to introduce message sequencing problems.  Perhaps such a check
could be added at the end of the hero's move....

This fix handles the cases where prayer causes a change to strength:
major: fix starvation, minor: fix weak from hunger, boon: golden glow
(restore strength and satisfy hunger--probably no-ops in this regard
or would have had trouble fixed rather than receive a boon).  Directly
curing stat loss (minor: poisoned) already dealt with encumbrance.

> Possibly related to the quirk whereby polymorphing into a form with
> different speed gives you one move movement at your old speed?
> (Polymorphing into a sessile monster gives you one last move.)

Not at all related.  That movement bug affected 3.6.0 but was fixed in
3.6.1.
This commit is contained in:
PatR
2018-10-26 16:35:21 -07:00
parent 2986a807de
commit 3f3bec8687
3 changed files with 14 additions and 4 deletions

View File

@@ -172,6 +172,8 @@ in Guidebook.mn and Guidebook.txt, the 'I' command mis-described `IX' as
displaying inventory items whose bless/curse state is "known"
(Guidebook.tex correctly had "unknown")
poison gas (stinking cloud) wasn't shown at drawbridge-up spot
prayer result which enhanced strength (fix weakness from hunger) didn't give
a message if a change in encumbrance occurred; it came on next move
Fixes to Post-3.6.1 Problems that Were Exposed Via git Repository