Difference between revisions of "Quest.txt format"
Jump to navigation
Jump to search
m (tiny fmt change) |
(text replacement chars) |
||
Line 2: | Line 2: | ||
{{stub|actually document the format here...}} | {{stub|actually document the format here...}} | ||
+ | |||
+ | |||
+ | ==Text Replacement Formatting== | ||
+ | The messages can contain special characters that will be replaced at run-time with some other data. For example in a string "<tt>Hello, %p</tt>" the "<tt>%p</tt>" would be replaced by the player's name. | ||
+ | |||
+ | {| class="prettytable striped" | ||
+ | |- | ||
+ | ! Code | ||
+ | ! Explanation | ||
+ | |- | ||
+ | | <tt>%p</tt> | ||
+ | | Player's name | ||
+ | |- | ||
+ | | <tt>%c</tt> | ||
+ | | Player's role, eg. "Archeologist" | ||
+ | |- | ||
+ | | <tt>%r</tt> | ||
+ | | Player's current rank title, eg. for an archeologist it could be "Field Worker" | ||
+ | |- | ||
+ | | <tt>%R</tt> | ||
+ | | Rank title required to get on the quest. | ||
+ | |- | ||
+ | | <tt>%s</tt> | ||
+ | | "sister" or "brother" | ||
+ | |- | ||
+ | | <tt>%S</tt> | ||
+ | | "daughter" or "son" | ||
+ | |- | ||
+ | | <tt>%l</tt> | ||
+ | | Name of the quest leader | ||
+ | |- | ||
+ | | <tt>%i</tt> | ||
+ | | Name of the intermediate level, eg. "the Tomb of the Toltec Kings" | ||
+ | |- | ||
+ | | <tt>%o</tt> | ||
+ | | Name of the quest artifact | ||
+ | |- | ||
+ | | <tt>%n</tt> | ||
+ | | Name of the quest nemesis | ||
+ | |- | ||
+ | | <tt>%g</tt> | ||
+ | | Name of the quest guardians | ||
+ | |- | ||
+ | | <tt>%G</tt> | ||
+ | | "god" or "goddess", depending on player's original alignment | ||
+ | |- | ||
+ | | <tt>%H</tt> | ||
+ | | Name of the quest home level | ||
+ | |- | ||
+ | | <tt>%a</tt> | ||
+ | | Player's original alignment | ||
+ | |- | ||
+ | | <tt>%A</tt> | ||
+ | | Player's current alignment | ||
+ | |- | ||
+ | | <tt>%d</tt> | ||
+ | | Player's original god | ||
+ | |- | ||
+ | | <tt>%D</tt> | ||
+ | | Name of the lawful god | ||
+ | |- | ||
+ | | <tt>%C</tt> | ||
+ | | "chaotic" | ||
+ | |- | ||
+ | | <tt>%L</tt> | ||
+ | | "lawful" | ||
+ | |- | ||
+ | | <tt>%N</tt> | ||
+ | | "neutral" | ||
+ | |- | ||
+ | | <tt>%x</tt> | ||
+ | | "see", or "sense" if player is blind | ||
+ | |- | ||
+ | | <tt>%Z</tt> | ||
+ | | Name of the first dungeon ("Dungeons of Doom") | ||
+ | |- | ||
+ | | <tt>%%</tt> | ||
+ | | "%" | ||
+ | |} | ||
+ | |||
*[[Source:NetHack 3.4.3/dat/quest.txt]] | *[[Source:NetHack 3.4.3/dat/quest.txt]] | ||
[[Category:Annotations]] | [[Category:Annotations]] |
Revision as of 07:59, 8 June 2013
quest.txt is a text data file residing in the NetHack source dat-directory. It contains text messages for the quest leaders, nemeses and guardians to say, and other texts related to the quests. It also contains angelic and demonic maledictions.
- 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:
"actually document the format here..."
Text Replacement Formatting
The messages can contain special characters that will be replaced at run-time with some other data. For example in a string "Hello, %p" the "%p" would be replaced by the player's name.
Code | Explanation |
---|---|
%p | Player's name |
%c | Player's role, eg. "Archeologist" |
%r | Player's current rank title, eg. for an archeologist it could be "Field Worker" |
%R | Rank title required to get on the quest. |
%s | "sister" or "brother" |
%S | "daughter" or "son" |
%l | Name of the quest leader |
%i | Name of the intermediate level, eg. "the Tomb of the Toltec Kings" |
%o | Name of the quest artifact |
%n | Name of the quest nemesis |
%g | Name of the quest guardians |
%G | "god" or "goddess", depending on player's original alignment |
%H | Name of the quest home level |
%a | Player's original alignment |
%A | Player's current alignment |
%d | Player's original god |
%D | Name of the lawful god |
%C | "chaotic" |
%L | "lawful" |
%N | "neutral" |
%x | "see", or "sense" if player is blind |
%Z | Name of the first dungeon ("Dungeons of Doom") |
%% | "%" |