mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-07 22:24:19 +00:00

Currently this is disabled by default Use --validate command-line argument to enable The following new features were added in the schema format: * Union, intersection, and list types * Keys can specify a union of known types on-the-fly * Key and tag names can include wildcards (* and ?, glob-style) * Tags support any_key=yes, which means unrecognized subtags will be ignored * Tags and keys support deprecated=yes (unimplemented) * Specify max=infinite instead of max=-1
67 lines
1.0 KiB
INI
67 lines
1.0 KiB
INI
|
|
#define SIMPLE_KEY NAME TYPE
|
|
[key]
|
|
name="{NAME}"
|
|
type="{TYPE}"
|
|
[/key]
|
|
#enddef
|
|
|
|
#define DEFAULT_KEY NAME TYPE DEFAULT
|
|
[key]
|
|
name="{NAME}"
|
|
type="{TYPE}"
|
|
default="{DEFAULT}"
|
|
[/key]
|
|
#enddef
|
|
|
|
#define REQUIRED_KEY NAME TYPE
|
|
[key]
|
|
name="{NAME}"
|
|
type="{TYPE}"
|
|
mandatory=yes
|
|
[/key]
|
|
#enddef
|
|
|
|
#define DEPRECATED_KEY NAME TYPE
|
|
[key]
|
|
name="{NAME}"
|
|
type="{TYPE}"
|
|
deprecated=yes
|
|
[/key]
|
|
#enddef
|
|
|
|
# Use to specify that unknown keys are always valid in a tag
|
|
#define ANY_KEY TYPE
|
|
[key]
|
|
name="*"
|
|
type="{TYPE}"
|
|
[/key]
|
|
#enddef
|
|
|
|
# Defines a tag that must contain no content
|
|
#define EMPTY_TAG NAME MIN MAX
|
|
[tag]
|
|
name="{NAME}"
|
|
min={MIN}
|
|
max={MAX}
|
|
[/tag]
|
|
#enddef
|
|
|
|
# Defines a tag that can contain any arbitrary content
|
|
#define DATA_TAG NAME MIN MAX
|
|
[tag]
|
|
name="{NAME}"
|
|
min={MIN}
|
|
max={MAX}
|
|
any_tag=yes
|
|
{SIMPLE_KEY * string}
|
|
[/tag]
|
|
#enddef
|
|
|
|
# These are "magic" keys allowed whenever two WML tags are merged.
|
|
#define WML_MERGE_KEYS
|
|
{SIMPLE_KEY __remove bool}
|
|
{SIMPLE_KEY add_to_* int}
|
|
{SIMPLE_KEY concat_to_* string}
|
|
#enddef
|