Data File Reference: Difference between revisions
No edit summary |
|||
Line 68: | Line 68: | ||
==DTD== | ==DTD== | ||
To edit data files in your XML editor, you can use the [[Data File DTD here]]. | To edit data files in your XML editor, you can use the [[Data File DTD|Data File DTD here]]. |
Revision as of 22:28, 23 June 2010
Context: HL Kit … Kit Reference
Overview
The data file is where you'll be defining all of the top-level elements that the user will directly control. This includes visual elements like panels, layouts, templates, and portals. It also includes game system elements like things.
All data files have the ".dat" file extension and are loaded after all of the structural files have defined the framework for the game system.
This section outlines the structure and mechanics for writing a definition file.
IMPORTANT! This section utilizes critical notational conventions that should be reviewed.
IMPORTANT! Just because you can put numerous different elements in the same file does not mean you should do so. Keeping your data files small and focused will also keep them much more manageable, so break up all the information across files where appropriate. See the Skeleton data files for examples of this.
Structural Composition
The overall file structure is that of a standard XML file. The file must start with an XML version element in the form: "<?xml version="1.0"?>". Following this, the top-level XML element must be a "document" and it must have a "signature" attribute containing the explicit value "Hero Lab Data".
The following table defines the attributes for a "document" element.
signature Text – Must be the value "Hero Lab Data".
Within the document element, every data file possesses the following child elements, appearing in the sequence given and with the names specified.
procedure Zero or more "procedure" elements may appear as defined by the given link. This element specifies a collection of procedures that may be called by scripts throughout the data files. thing Zero or more "thing" elements may appear as defined by the given link. This element specifies various thing objects for use within the game system. portal Zero or more "portal" elements may appear as defined by the given link. This element specifies an assortment of portals for use within layouts. template Zero or more "template" elements may appear as defined by the given link. This element specifies an assortment of templates for use within layouts. layout Zero or more "layout" elements may appear as defined by the given link. This element specifies an assortment of layouts for use within panels, forms, and sheets. panel Zero or more "panel" elements may appear as defined by the given link. This element specifies a variety of panels that will be presented to the user as part of the game system. form Zero or more "form" elements may appear as defined by the given link. This element specifies a variety of forms that will be presented to the user as part of the game system. sheet Zero or more "sheet" elements may appear as defined by the given link. This element specifies a variety of sheets that will be used for printouts within dossiers. dossier Zero or more "dossier" elements may appear as defined by the given link. This element specifies a collection of dossiers that the user can select for character output. hidden Zero or more "hidden" elements may appear as defined by the given link. This element identifies things that HL should remove from use within the game system. editthing Zero or more "editthing" elements may appear as defined by the given link. This element specifies a variety of elements that enable use of the integrated Editor for creation of things. faq Zero or more "faq" elements may appear as defined by the given link. This element specifies various FAQ entries that will be included within the FAQ page for the game system.
DTD
To edit data files in your XML editor, you can use the Data File DTD here.