add customcolors option

customcolors (default) and !customcolors toggle whether the
custom colors get applied to the glyphmap.
This commit is contained in:
nhmall
2024-03-24 16:55:23 -04:00
parent f5c3445e80
commit 0b35079acc
8 changed files with 46 additions and 19 deletions

View File

@@ -752,6 +752,7 @@ struct instance_globals_o {
boolean opt_need_redraw; /* for doset() */
boolean opt_need_glyph_reset;
boolean opt_need_promptstyle;
boolean opt_reset_customizations;
/* pickup.c */
int oldcap; /* last encumbrance */

View File

@@ -1110,6 +1110,8 @@ extern void apply_customizations(enum graphics_sets which_set);
extern void purge_custom_entries(enum graphics_sets which_set);
extern void purge_all_custom_entries(void);
extern void dump_glyphids(void);
extern void clear_all_glyphmap_colors(void);
extern void reset_customizations(void);
/* ### hack.c ### */
@@ -3031,7 +3033,6 @@ extern const struct symparse *match_sym(char *) NONNULLARG1;
extern void savedsym_free(void);
extern void savedsym_strbuf(strbuf_t *) NONNULLARG1;
extern boolean parsesymbols(char *, int) NONNULLARG1;
extern void clear_all_glyphmap_colors(void);
/* ### sys.c ### */

View File

@@ -375,6 +375,7 @@ struct instance_flags {
boolean fireassist; /* autowield launcher when using fire-command */
boolean wizweight; /* display weight of everything in wizard mode */
boolean wizmgender; /* test gender info from core in window port */
boolean customcolors; /* support customcolors defined in glyphmap */
/*
* Window capability support.
*/

View File

@@ -250,6 +250,9 @@ static int optfn_##a(int, int, boolean, char *, char *);
No, Yes, No, No, NoAlias,
"load curses display symbols into symset")
#endif
NHOPTB(customcolors, Map, 0, opt_out, set_in_game,
On, Yes, No, No, "customcolours", &iflags.customcolors,
Term_False, "use custom colors in map")
NHOPTB(dark_room, Advanced, 0, opt_out, set_in_game,
On, Yes, No, No, NoAlias, &flags.dark_room, Term_False,
"show floor outside line of sight differently")