]> granicus.if.org Git - nethack/commit
more symbol stuff (trunk only)
authornethack.allison <nethack.allison>
Sun, 1 Oct 2006 19:30:08 +0000 (19:30 +0000)
committernethack.allison <nethack.allison>
Sun, 1 Oct 2006 19:30:08 +0000 (19:30 +0000)
commit374e9fbbb4d05f66d1545ee6f62f9fefbefe6f94
treec21e6765343853d6dd9ff641be1b8cd06eeb3a73
parentfb8261769a3121a7d54055e52f2f82dbeb0e2141
more symbol stuff (trunk only)

- reduce the number of symbol tables for each graphics
set {PRIMARY, ROGUESET} from three {map, oc, mon}
tables for each of the display symbols, the loadable symbols,
and the rogue symbols, to one continguous table for
each:
showsyms: the current display symbols
l_syms: the loaded, alterable symbols
r_syms: the rogue symbols

- Modify mapglyph so that the index into the symbolt table is
available as a return value (it was a void function), rather than
just the char converted from the glyph.
- That makes it possible for a window port to use the same
index value to extract from another table (perhaps a unicode
table) for a different set of display symbols. The  index
is much more useful than trying to convert the character
into another type of symbol, as some contributed patches
have done.
- It is much easier to load a single alternative flat table to
make substitutions, since the corresponding value just
has to get placed into the same index offset in the
alternative table.

This also fixes a bug I found in botl.c, where you could
go to the rogue level, and the bottom line gold symbol
was not being updated with the new character as it should.
The reason was because the gold value had not changed,
only the field symbol used had changed.

This updates multiple ports to place a (void) cast on
the mapglyph call, now that it returns a value, so this
is going to generate a lot of diff e-mails.
18 files changed:
doc/window.doc
include/extern.h
include/hack.h
include/rm.h
src/botl.c
src/drawing.c
src/files.c
src/mapglyph.c
src/options.c
src/pager.c
sys/amiga/winfuncs.c
sys/wince/mhmap.c
sys/wince/mhstatus.c
win/Qt/qt_win.cpp
win/X11/winmap.c
win/gem/wingem.c
win/tty/wintty.c
win/win32/mhmap.c