Go to the first, previous, next, last section, table of contents.

Game Module Forms

The game module declaration supplies information about the file as a whole. It is optional; if missing, Xconq will get the module's name from its file name, and supply defaults for the other properties.

Form: game-module [name] properties...

This form defines the properties of this game module. The optional name is a string that will be used to look up the module in libraries. If the name is supplied, then this form is considered to be the definition of the module, and overwrites any game-module form previously appearing in this file. If name is missing, then this form will modify the existing description of the module.

ModuleProperty: title string

If defined, this property is the name by which the module will be displayed to players. It is not used internally, so the name can be modified freely (unlike the module's name, which may appear in other modules). Defaults to the module's name.

ModuleProperty: blurb string

This property is a one-line description that users will see when they are deciding whether to play the module. It will be displayed without any modification:

Welcome to my nightmare! (version 1.0 with stronger goblins)

Defaults to "".

ModuleProperty: picture-name string

This property is the name of a picture that may be displayed along with the module's blurb, by those interfaces that support such pictures. Defaults to "".

ModuleProperty: base-game t/f

ModuleProperty: instructions strings...

This property is a list of strings that are the instructions on how to play the game. Defaults to ().

ModuleProperty: notes strings...

This property is a list of strings comprising the set of detailed player's notes for the module. Both the list and each string in the list can be of any length. When displayed, the strings are all concatenated together, so the division into strings here is just for convenience. How these are displayed is up to the interface, but in general an empty string signals a new paragraph. Defaults to ().

ModuleProperty: design-notes strings...

This property is a list of strings that are notes addressed to game designers. Defaults to ().

ModuleProperty: version string

This property is the version of the module. Defaults to "", which indicates that the module's version is undefined.

ModuleProperty: program-version versions

This property dentifies Xconq versions for which this module is appropriate. If specified, then players will get a warning if they attempt to use this module with an inappropriate version of Xconq. Possible forms include a string, which allows the module only for exactly matching version of Xconq, and (comparison version), which allows versions satisfying the comparison test, which may only be >= or <=. So for instance

(game-module "foo" (program-version (>= "7.0.3")))

is claimed to only work for versions 7.0.3 or later. Defaults to "", which means that the module is appropriate for any version of Xconq.

Notes that the program-version is strictly a heuristic to forewarn players; in practice it can be very difficult to know which modules work with which programs. (The problems are similar to those encountered by programmers using different compiler versions on their programs.)

ModuleProperty: base-module name

This property is the name of a module that must be loaded first. It is similar in effect to include.

ModuleProperty: default-base-module name

This property specifies the name of a module that will be loaded if this module is given as the "top-level" module, such as via -g on a command line.

This is to prevent disasters when a library module that is used only by other modules is instead loaded as if it were a full game design.


Go to the first, previous, next, last section, table of contents.