Skip to content

Treasure

Examples

Example

<Treasure>
  <CollectTime>
    1000
  </CollectTime>
  <Resources>
    <Food>
      1000
    </Food>
  </Resources>
</Treasure>

XML Elements

The following elements can be used within this component:

Treasure

CollectTime

Amount of milliseconds that it takes to collect this treasure.

Type: non-negative decimal

Path: Treasure/CollectTime

Resources

Amount of resources that are in this.

Path: Treasure/Resources

food

Type: positive decimal

Path: Treasure/Resources/food

wood

Type: positive decimal

Path: Treasure/Resources/wood

stone

Type: positive decimal

Path: Treasure/Resources/stone

metal

Type: positive decimal

Path: Treasure/Resources/metal

RELAX NG Grammar

<define name="component.Treasure">
  <element name="Treasure">
    <interleave>
      <element name="CollectTime">
        <ref name="nonNegativeDecimal"/>
      </element>
      <optional>
        <element name="Resources">
          <interleave>
            <optional>
              <element name="food">
                <ref name="positiveDecimal"/>
              </element>
            </optional>
            <optional>
              <element name="wood">
                <ref name="positiveDecimal"/>
              </element>
            </optional>
            <optional>
              <element name="stone">
                <ref name="positiveDecimal"/>
              </element>
            </optional>
            <optional>
              <element name="metal">
                <ref name="positiveDecimal"/>
              </element>
            </optional>
          </interleave>
        </element>
      </optional>
    </interleave>
  </element>
</define>