fix #H7156 - perm_invent
Bug report #H7156 listed three items, all relating to perm_invent: 1) it shouldn't persist across save/restore since restore might be on a system which doesn't have enough room to display it (report actually complained that config file setting was ignored when restoring old games, which is an expected side-effect for options that persist across save/restore); 2) permanent inventory wasn't updated when using scroll of charging; 3) attempts to update permanent inventory during restore could lead to crash if it tries to access shop cost for unpaid items. Items (2) and (3) have already been fixed. This fixes (1). Replace 'flags.perm_invent' with a dummy flag, preserving save files while removing it from flags. Add 'iflags.perm_invent' to hold the value of the perm_invent option. The win32 files that are updated here haven't been tested. Whichever branch contains the curses interface needs to be updated; ditto for any other pending/potential interfaces which support perm_invent.
This commit is contained in:
@@ -3004,7 +3004,6 @@ such as ``paranoid_confirmation:attack pray Remove''.
|
||||
.lp perm_invent
|
||||
If true, always display your current inventory in a window. This only
|
||||
makes sense for windowing system interfaces that implement this feature.
|
||||
Persistent.
|
||||
.lp pettype
|
||||
Specify the type of your initial pet, if you are playing a character class
|
||||
that uses multiple types of pets; or choose to have no initial pet at all.
|
||||
|
||||
@@ -3501,7 +3501,6 @@ such as ``{\it par\-a\-noid\verb+_+con\-fir\-ma\-tion:attack~pray~Remove}''.
|
||||
\item[\ib{perm\verb+_+invent}]
|
||||
If true, always display your current inventory in a window. This only
|
||||
makes sense for windowing system interfaces that implement this feature.
|
||||
Persistent.
|
||||
%.lp
|
||||
\item[\ib{pettype}]
|
||||
Specify the type of your initial pet, if you are playing a character class
|
||||
|
||||
@@ -136,6 +136,8 @@ tty: ensure that current status fields are always copied to prior status
|
||||
|
||||
Platform- and/or Interface-Specific Fixes
|
||||
-----------------------------------------
|
||||
move 'perm_invent' value from flags to iflags to keep it out of save files;
|
||||
affects X11, win32, and curses
|
||||
windows-gui: In nethackw, there could be conflicts between menu accelerators
|
||||
and an extra choice accelerator to fix H7132.
|
||||
windows-gui: recognize new BL_RESET in status_update; no change in behavior yet
|
||||
|
||||
Reference in New Issue
Block a user