IBMgraphics
IBMgraphics is an option that displays walls as continuous lines rather than as broken dashes, which is the best that plain ASCII can do. It also displays certain dungeon features with distinct symbols, and on some systems makes the Rogue level look more like the Epyx version of Rogue.
IBMgraphics requires a display device that displays code page 437, or a compatible code page. Many users of Microsoft Windows outside the United States have their terminals set to another code page, often code page 850, and this can affect the appearance of some symbols.
Contents
The complete symbol list
Normal dungeon
The complete symbol list for the normal dungeon is found in the array ibm_graphics in drawing.c.[1] The corresponding ASCII symbols are in defsyms.[2] Those symbols affected by IBMgraphics are listed here.
Code point | Usage | Appearance | ASCII |
---|---|---|---|
0xB3 | Vertical wall, beam, explosion | │ | | |
0xC4 | Horizontal wall or beam | ─ | - |
0xDA | Top left corner | ┌ | - |
0xBF | Top right corner | ┐ | - |
0xC0 | Bottom left corner | └ | - |
0xD9 | Bottom right corner | ┘ | - |
0xC5 | Cross wall | ┼ | - |
0xC1 | T-up wall | ┴ | - |
0xC2 | T-down wall | ┬ | - |
0xB4 | T-left wall | ┤ | | |
0xC3 | T-right wall | ├ | | |
0xB0 | Dark corridor | ░ | # |
0xB1 | Lit corridor | ▒ | # |
0xF0 | Iron bars | ≡ | # |
0xF1 | Tree | ± | # |
0xF4 | Fountain | ⌠ | { |
0xF7 | Lava, pool, water | ≈ | } |
0xFA | Room, doorway, ice, open drawbridge | · | . |
0xFE | Open door | ■ | | or - |
Rogue level
Certain objects have their appearance changed in the Rogue level; the array IBM_r_oc_syms governs this.[3] The exact changes are different on Linux than on MS-DOS and its descendants. The list here shows the more complete list used on MS-DOS.
A number of map symbols are also changed[4] and all creatures otherwise appearing as @ instead appear as ☺.[5]
Code point | Usage | Appearance | ASCII |
---|---|---|---|
0xBA | Vertical wall | ║ | | |
0xCD | Horizontal wall | ═ | - |
0xC9 | Top left corner | ╔ | - |
0xBB | Top right corner | ╗ | - |
0xC8 | Bottom left corner | ╚ | - |
0xBC | Bottom right corner | ╝ | - |
0xCE | Cross wall, doors | ╬ | - or + |
0xCA | T-up wall | ╩ | - |
0xCB | T-down wall | ╦ | - |
0xB9 | T-left wall | ╣ | | |
0xCC | T-right wall | ╠ | | |
0x01 | Human, elf | ☺ | @ |
0x04 | Trap, web | ♦ | ^ or " |
0x05 | Food | ♣ | : |
0x0C | Amulet | ♀ | , |
0x0E | Scroll | ♫ | ? |
0x0F | Gold, gems | ☼ | * |
0x18 | Weapon | ↑ | ) |
0x5B | Armor | [ | ] |
0xAD | Potion | ¡ | ! |
0xB1 | Dark corridor | ▒ | # |
0xB2 | Lit corridor | ▓ | # |
0xE7 | Wand | τ | / |
0xF0 | Stairs | ≡ | % |
0xFA | Room | · | . |
Code page compatibility
There are code pages other than 437 that will also display IBMgraphics correctly, because they differ only at code points that are not currently used by NetHack. These include 860 (Portuguese), 861 (Icelandic), 862 (Hebrew), and 865 (Nordic), and can be useful when code page 437 is unavailable.
Some other code pages will not quite display IBMgraphics perfectly, but are close enough to be usable when none of the above code pages are available. Some of these are shown in the table below.
For code page 858, use the column for code page 850.
Other known code pages have few of the necessary symbols and are completely unsuitable for IBMgraphics.
Code point | CP437 | CP737 | CP775 | CP850 | CP852 | CP855 | CP857 | CP863 | CP866 | CP869 |
---|---|---|---|---|---|---|---|---|---|---|
0xAD | ¡ | φ | Ł | ¡ | ş | Г | ¡ | ¾ | н | Ι |
0xE7 | τ | ύ | ń | þ | š | у | none | τ | ч | ν |
0xF0 | ≡ | Ώ | - | - | - | - | - | ≡ | Ё | - |
0xF1 | ± | ± | ± | ± | ˝ | ы | ± | ± | ё | ± |
0xF4 | ⌠ | Ϊ | ¶ | ¶ | ˘ | З | ¶ | ⌠ | Ї | χ |
0xF7 | ≈ | ≈ | „ | ¸ | ¸ | э | ¸ | ≈ | ў | ΅ |
0xFA | · | · | · | · | ˙ | Щ | · | · | · | ω |
Configuring Code Page 437
On many platforms, it is possible to set the display device to display code page 437 instead of the default code page. This will enable NetHack to display the IBMgraphics as the DevTeam intended.
MS-DOS and Windows 95, 98, and Me
- This page is a stub. Should you wish to do so, you can contribute by expanding this page.
A user has suggested improving this page or section as follows:
"It is necessary to add certain lines to CONFIG.SYS for these platforms."
Windows NT, 2000, XP, and Vista
This section may also apply to Windows 2003 Server, but is untested on this version.
If code page 437 is not the default, it will be necessary either to configure the console window to use the Lucida Console font, or to run full screen (press Alt-Enter). With bitmap fonts in a window, only the characters for the default code page are loaded, and others do not display correctly. Bug W343-3 is also a problem for this configuration.
Once either Lucida Console is set, or the console window is in full screen mode, it is sufficient to type
chcp 437
and possibly for full-screen mode
mode con lines=25
and then start NetHack.
PuTTY
On the PuTTY Configuration window (this appears when you first start PuTTY), select "Translation" under the "Window" configuration in the pane on the left. Then, in the pulldown menu marked "Received data assumed to be in which character set", select "CP437". You can then log in to the server as usual.
Linux Console
On Debian-based distributions, the command is
consolechars -f default8x16
On many others, the command is
setfont default8x16
X11
The usual way is to obtain a VGA font, and set the terminal program to use it. The exact procedure depends on the terminal program in use. Users of X11 may find it easier to use DECgraphics instead.
xterm
- This page is a stub. Should you wish to do so, you can contribute by expanding this page.
Konsole (KDE)
- This page is a stub. Should you wish to do so, you can contribute by expanding this page.
gnome-terminal
The current gnome-terminal comes with a setting for code page 850, but not for 437; some users may find it easier to set code page 850 and live with the differences listed above.
To set code page 850 on gnome-terminal:
- Select Terminal, Set Character Encoding, and then Add or Remove.
- In the pane on the left, select the line with description Western and encoding IBM850.
- Click the right-pointing arrow between the two panes.
- Click Close.
The above steps only need to be done once for the lifetime of the Gnome installation. Once done, it is sufficient to:
- Select Terminal, Set Character Encoding, and then Western (IBM850).
- This page is a stub. Should you wish to do so, you can contribute by expanding this page.
Custom Map Symbols
Some users may prefer to set their own symbols, either because they don't like the existing ones, or because it's easier than setting code page 437 just to play NetHack. See Custom map symbols for further details.
UTF-8 support
A user has posted an experimental patch to RGRN (here's what it changes) allowing display of the IBMgraphics characters using UTF-8, rather than a special code page. Compatible terminals include the Linux console for kernels since 1.2.1, any Unix-like platform running a recent version of X11, and PuTTY for Windows users accessing public servers. It is a patch against NetHack 3.4.0, but should be easily adaptable for 3.4.3.