black and white ice, sink

When moat and lava use the same screen symbol and color is Off, lava
is rendered in inverse video.  It used to be similar for floor and
ice, but that got broken last year.  Fix inverse ice, and now that
fountain and sink might be same symbol (recent IBMgraphics change),
render sinks in inverse if they match fountains and color is Off.

I started to give sink its own mapglyph flag but then got lazy and
used the same value as ice.  That can be amended if some interface
wants to use some more elaborate distinction than inverse video.
This commit is contained in:
PatR
2022-08-23 16:01:35 -07:00
parent 50b91bdcfa
commit 422a06f01f
5 changed files with 30 additions and 14 deletions

View File

@@ -1,4 +1,4 @@
/* NetHack 3.7 display.h $NHDT-Date: 1652719570 2022/05/16 16:46:10 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.71 $ */
/* NetHack 3.7 display.h $NHDT-Date: 1661295667 2022/08/23 23:01:07 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.77 $ */
/* Copyright (c) Dean Luick, with acknowledgements to Kevin Darcy */
/* and Dave Cohrs, 1990. */
/* NetHack may be freely redistributed. See license for details. */
@@ -979,6 +979,8 @@ enum glyph_offsets {
#define MG_BW_LAVA 0x00100 /* 'black & white lava': highlight lava if it
* can't be distinguished from water by color */
#define MG_BW_ICE 0x00200 /* similar for ice vs floor */
#define MG_BW_SINK 0x00200 /* identical for sink vs fountain [note: someday
* this may become a distinct flag */
#define MG_NOTHING 0x00400 /* char represents GLYPH_NOTHING */
#define MG_UNEXPL 0x00800 /* char represents GLYPH_UNEXPLORED */
#define MG_MALE 0x01000 /* represents a male mon or statue of one */