experimental hitpointbar change

For tty, make hitpointbar blink if current HP falls to the critical
HP threshold.  Doesn't require status highlighting.  Not changed:
when status highlighting is active, use the HP color but force the
attribute to be inverse (plus blink if the criterium is met) rather
than whatever the HP highlight specifies.

For curses, do the same thing.  It used to honor HP attribute for
hitpointbar, now it behaves the same as tty:  always inverse, maybe
combined with blink.  The new code assumes that inverse and color
can be turned off without turning off active blink in the process.

I had intended to make hitpointbar be a full-fledged status field
(which happens to be rendered on top of title) so that it could be
highlighted differently from hit points (mainly so that one could
highlight up and down changes while the other showed percentages).
This is less versatile than that but much simpler.
This commit is contained in:
PatR
2024-04-11 11:06:29 -07:00
parent 16c693eedf
commit 7da370d74a
5 changed files with 57 additions and 24 deletions

View File

@@ -268,6 +268,7 @@ extern boolean exp_percent_changing(void);
extern int stat_cap_indx(void);
extern int stat_hunger_indx(void);
extern const char *bl_idx_to_fldname(int);
extern void repad_with_dashes(char *);
extern void condopt(int, boolean *, boolean);
extern int parse_cond_option(boolean, char *);
extern boolean cond_menu(void);