Skip to content

Definition Format

infinity8 edited this page Sep 3, 2016 · 8 revisions

The definition supports a fair number of different element types, detailed below. The available types and their parameters are listed in the core.xmldef file.

#General Parameters The following parameters are found on all types.

Name

This specifies the name that this element will be written out with.

SkipIfDefault

When set to true this will skip writing this element if it is at its default value.

VisibleIf

This allows for specifying a simple expression to conditionally hide/show an element. Consists of a series of boolean expressions seperated by && (or is not supported).

TextColour

The colour of the name of this element in the ui.

Tooltip

An optional tooltip to show on mouseover for this element.

Primitive

Primitive types are the types that can be represented simply as a single string. This means they can be converted into comma seperated lists by structs / collections that are set to collapse. Primitives also allow for specifying a default value.

Boolean

This represents a simple true/false value.

Colour

This represents a colour, with optional alpha. Is written out as a comma seperated list of 0-255 values, in the order rgb (or rgba if using alpha).

Enum

This represents a collection of values that can be chosen from. The values can be specified within this element or loaded from another location by using the enumdef element.

File

This represents a filepath, relative to the project root. An optional extra path can be specified to change the base path if desired. Additionally the allowed file types can be configured.

Number

This represents a number. It can either be a int or float, and you can also set a min and max value allowed.

String

This is a string. Nothing fancy here.

Vector

This represents a mathematical vector (currently only with 2 parameters, x and y). These values will be joined by commas when written out in the format x,y.

Complex

Clone this wiki locally