Difference between revisions of "Vt tiledata"

From NetHackWiki
Jump to navigation Jump to search
(Added 3.6.1 examples; removed unneccessary statement about 3.6.0.)
m ((Hopefully) better formatting...)
Line 12: Line 12:
  
 
==Escape codes==
 
==Escape codes==
All of the escape codes are in the format <tt>ESC [ N z</tt> (<tt>ESC [ 1 ; N z</tt> in 3.6.1), where N can be one or more positive integer values, semicolon-seperated. For example, <tt>ESC [ 0 ; 120 z</tt> (<tt>ESC [ 1 ; 0 ; 120 z</tt> in 3.6.1).
+
All of the escape codes are in the format <tt>ESC [ N z</tt> (3.4.3 patch) or <tt>ESC [ 1 ; N z</tt> (3.6.1), where N can be one or more positive integer values, semicolon-seperated. For example, <tt>ESC [ 0 ; 120 z</tt> (3.4.3 patch) or <tt>ESC [ 1 ; 0 ; 120 z</tt> (3.6.1).
  
 
3.4.3-NAO uses the following codes:
 
3.4.3-NAO uses the following codes:
Line 28: Line 28:
 
Whenever NetHack outputs anything, it will first output the select window code.
 
Whenever NetHack outputs anything, it will first output the select window code.
 
Whenever NetHack outputs a tile, it will first output the start glyph code, then the escape codes for color and the glyph character itself, and then the end glyph code.
 
Whenever NetHack outputs a tile, it will first output the start glyph code, then the escape codes for color and the glyph character itself, and then the end glyph code.
 
  
 
==Support==
 
==Support==

Revision as of 18:30, 22 January 2019

Telnet Tiles Server
Author Justin Hiltscher
Download unknown
NetHack PatchDB 123

vt_tiledata is a community patch for NetHack that adds extra escape codes into the data stream, mainly intended for graphical frontends. The name vt_tiledata comes from the boolean option used in version 3.4.3 on NAO.

The original patch, called Telnet Tiles, was made by Justin Hiltscher. That patch only sent one type of escape code, the version NAO used for 3.4.3 added some extra codes.

The Dev Team added this patch to vanilla NetHack for version 3.6.1 with a few changes (see below).

Escape codes

All of the escape codes are in the format ESC [ N z (3.4.3 patch) or ESC [ 1 ; N z (3.6.1), where N can be one or more positive integer values, semicolon-seperated. For example, ESC [ 0 ; 120 z (3.4.3 patch) or ESC [ 1 ; 0 ; 120 z (3.6.1).

3.4.3-NAO uses the following codes:

  • ESC [ 0 ; n z: Start a glyph (aka a tile) number n.
  • ESC [ 1 z: End a glyph.
  • ESC [ 2 ; n z: Select a window n to output to.
  • ESC [ 3 z: End of data. NetHack has finished sending data to you, and is waiting for your input.

3.6.1 uses the following codes: [1]

  • ESC [ 1 ; 0 ; n ; m z: Start a glyph (aka a tile) number n, with flags m
  • ESC [ 1 ; 1 z: End a glyph.
  • ESC [ 1 ; 2 ; n z: Select a window n to output to.
  • ESC [ 1 ; 3 z: End of data. NetHack has finished sending data, and is waiting for input.

Whenever NetHack outputs anything, it will first output the select window code. Whenever NetHack outputs a tile, it will first output the start glyph code, then the escape codes for color and the glyph character itself, and then the end glyph code.

Support

Currently the escape codes are supported by EbonHack, Soiled, and webhack.webhook.org. Some terminal emulators do not like unknown escape codes - For example gnome-terminal prints these escape codes on the screen.

References