wizard mode buglet: simultaneous Lev+Fly timeout

Noticed while working on Qt status highlighting:  if levitation
and flying timed out at the same time, first Lev timeout called
float_down() which reported
 You have stopped levitating and are now flying.
and then Fly timeout left stale "Fly" on the status line due to
an optimization which got subverted.  ('was_flying' flag was
False due to Fly being blocked by Lev; that's correct behavior,
but the flag is effectively a cached value that becomes stale
when the Lev timeout code executes.)

The bug was wizard mode only because #wizintrinsic is the only
way to get timed flying.
This commit is contained in:
PatR
2020-11-24 10:43:12 -08:00
parent 018d838eb9
commit 7e87abb66f
2 changed files with 21 additions and 8 deletions

View File

@@ -1,4 +1,4 @@
NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.361 $ $NHDT-Date: 1606033928 2020/11/22 08:32:08 $
NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.362 $ $NHDT-Date: 1606243387 2020/11/24 18:43:07 $
General Fixes and Modified Features
-----------------------------------
@@ -305,6 +305,9 @@ wand/scroll of create monster or bag of tricks that makes a new monster which
concealed mimic seen as furniture or an object
'showscore' could be used to determine how much gold was inside a container
whose contents were unknown
wizard mode (only way to get timed flying): if levitation and flying time out
on same turn, player was told "You have stopped levitating and are
now flying."; status line wasn't updated to remove stale Fly condition
Fixes to 3.7.0-x Problems that Were Exposed Via git Repository