From: Pasi Kallinen Date: Thu, 18 Jun 2015 17:55:09 +0000 (+0300) Subject: Fix default boulder symbol X-Git-Tag: NetHack-3.6.0_RC01~258^2~8 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2094aa16ad9bd8937caced5bdf4d2b9550fada52;p=nethack Fix default boulder symbol Previous boulder symbol fix unearthed another problem: When no boulder symbol was defined in config file, the default iflags.bouldersym null value was used as a symbol. --- diff --git a/src/drawing.c b/src/drawing.c index a78e3d5e5..1a5be65be 100644 --- a/src/drawing.c +++ b/src/drawing.c @@ -375,7 +375,7 @@ init_showsyms() for (i = 0; i < MAXOTHER; i++) { if (i == SYM_BOULDER) - showsyms[i + SYM_OFF_X] = iflags.bouldersym; + showsyms[i + SYM_OFF_X] = iflags.bouldersym ? iflags.bouldersym : def_oc_syms[ROCK_CLASS].sym; else if (i == SYM_INVISIBLE) showsyms[i + SYM_OFF_X] = DEF_INVISIBLE; } @@ -401,7 +401,7 @@ init_l_symbols() for (i = 0; i < MAXOTHER; i++) { if (i == SYM_BOULDER) - l_syms[i + SYM_OFF_X] = iflags.bouldersym; + l_syms[i + SYM_OFF_X] = iflags.bouldersym ? iflags.bouldersym : def_oc_syms[ROCK_CLASS].sym; else if (i == SYM_INVISIBLE) l_syms[i + SYM_OFF_X] = DEF_INVISIBLE; } @@ -433,7 +433,7 @@ init_r_symbols() for (i = 0; i < MAXOTHER; i++) { if (i == SYM_BOULDER) - r_syms[i + SYM_OFF_X] = iflags.bouldersym; + r_syms[i + SYM_OFF_X] = iflags.bouldersym ? iflags.bouldersym : def_oc_syms[ROCK_CLASS].sym; else if (i == SYM_INVISIBLE) r_syms[i + SYM_OFF_X] = DEF_INVISIBLE; }