Quetzal is a standardised file format for the saved state of
Z-machine games, invented by
Martin Frost. Prior to the introduction of Quetzal, each Z-machine interpreter saved games in its own format; Quetzal enabled players to save a game using one interpreter and restore it with another. Use of the format is strongly recommended in
Graham Nelson
Graham A. Nelson (born 1968) is a British mathematician, poet, and the creator of the Inform, Inform design system for creating interactive fiction (IF) games. He has authored several IF games, including ''Curses (computer game), Curses'' (1993) ...
's Z-machine standards document, but not obligatory. Most modern Z-machine interpreters have the ability to save Quetzal files.
The files are
IFF
In logic and related fields such as mathematics and philosophy, "if and only if" (often shortened as "iff") is paraphrased by the biconditional, a logical connective between statements. The biconditional is true in two cases, where either both ...
files with a FORM of "IFZS" (presumably standing for "
Interactive Fiction
Interactive fiction (IF) is software simulating environments in which players use text Command (computing), commands to control Player character, characters and influence the environment. Works in this form can be understood as literary narrati ...
Z-machine Save"), although the saved files are commonly given an extension of ".sav": less commonly sighted are "quz" and "qtz". Despite the reference to the Z-machine in the FORM code, the format has proved flexible enough to be adapted for at least one alternative architecture,
Glulx.
The magic-number reading of the files are often shown as:
'IFF data, Z-machine or Glulx saved game file (Quetzal)'
A
backronym
A backronym is an acronym formed from an already existing word by expanding its letters into the words of a phrase. Backronyms may be invented with either serious or humorous intent, or they may be a type of false etymology or folk etymology. The ...
for the format is "Quetzal Unifies Efficiently The Z-Machine Archive Language".
Version 1.3b, which was widely available, contained a bug later corrected in version 1.4: after a save instruction, the Z-machine requires that a success code is saved in a particular place (which differs depending on the version). Versions of the Quetzal standard before 1.4 have reference only to the instruction ''after'' the save, which complicates finding the correct place to put the success code.
External links
Version 1.4 of the specification
Computer file formats