Skip to content

XML Tag File Specification#

The format for tag files is still in its early stages. While we will try to avoid any breaking changes, don't be too surprised if any major format changes occur.

Tags are the primary way that any game content will be stored.

Tag data will vary wildly based on a class, but the following format details are consistent across all tags. XML tags, or "decompiled" tags, are used by the Editing Kit and, as the name implies, are stored as an XML document. Tags stored in this format will take up more disk space, but are able to be significantly more resilient to format changes. When creating or working with any project in Blamite, all tags should be stored in this format.

Note that the game engine itself cannot interact with these tags in any way. As a result, the Editing Kit will compile the tag as part of the save process, ensuring the engine is able to read the updated tag.

Root Node#

The name of the root node will always be the long class name. In the example below, a scenario tag is used - whose short name is scnr, and whose long name is scenario.

<scenario pluginVersion="2">
...
</scenario>

| Attribute Name | Type | Description | | --- | --- | --- | --- | | pluginVersion | Integer | The version of the plugin that this tag was created from. |

Tag Fields#

Standard Fields#

Most tag fields share a common, standard format.

<type id="field_id">value</type>

| Attribute Name | Type | Description | | --- | --- | --- | --- | | id | String | The unique identifier of the field. |

Below is a list of all possible common field types, and the data type that corresponds to the field in-engine.

| Name | Data Type | Description | | --- | --- | --- | --- | | int8 | int8_t | An 8-bit signed integer. | | int16 | int16_t | A 16-bit signed integer. | | int32 | int (int32_t) | A 32-bit signed integer. | | real, float32 | float | A 32-bit floating-point number. | | enum32 | int (int32_t) | A 32-bit enumerator value. | | bitfield8 | int8_t | A collection of up to 8 boolean flags. | | bitfield16 | int16_t | A collection of up to 16 boolean flags. | | bitfield32 | int (int32_t) | A collection of up to 32 boolean flags. | | dataref | data_reference | A general-purpose data reference. Can store any arbitrary data. | | tagref | tag_reference | A reference to another tag. Will contain a string with the path of the referenced tag. | | unknown | N/A | An unknown field type. Will only ever be used in the case of an error as a fallback, though data will likely not be saved. |

Deprecated Field Types#

The below common field types are deprecated and will be removed in the future.

| Name | Data Type | Description | | --- | --- | --- | --- | | enum8 | int8_t | An 8-bit enumerator value. Deprecated due to buggy behavior within the engine - all enums are treated as 32-bit enums in C++, and there is little reason to support these as such. | | enum16 | int16_t | A 16-bit enumerator value. Deprecated due to buggy behavior within the engine - all enums are treated as 32-bit enums in C++, and there is little reason to support these as such. | | ascii | ascii (char[128]) | A string, up to 128 characters in length. Deprecated as datarefs and/or a future string field should be used instead. |

Specific Fields#

Some fields are stored in a different, specific format or have additional attributes. Those fields are listed below.

Tag Blocks#

Tag blocks store their entries as separate child nodes.

<tagblock id="field_id">
    <entry name="entry 1">
        ...
    </entry>
    <entry name="entry 2">
        ...
    </entry>
</tagblock>

Each <entry> node will contain a list of all fields within it. Each entry will also have the following attributes:

| Name | Type | Description | | --- | --- | --- | --- | | name | String | The display name of the entry. |