Skip to content

Trainer

Examples

Example

<Trainer>
  <BatchTimeModifier>
    0.7
  </BatchTimeModifier>
  <Entities datatype="tokens">
    units/{civ}/support_civilian
    units/{native}/support_trader
    units/athen/infantry_spearman_b
  </Entities>
</Trainer>

XML Elements

The following elements can be used within this component:

Trainer

BatchTimeModifier

Modifier that influences the time benefit for batch training. Defaults to 1, which means no benefit.

Type: non-negative decimal

Path: Trainer/BatchTimeModifier

Entities

Space-separated list of entity template names that this entity can train. The special string "{civ}" will be automatically replaced by the civ code of the entity's owner, while the string "{native}" will be automatically replaced by the entity's civ code.

Type: text

Path: Trainer/Entities

RELAX NG Grammar

<define name="component.Trainer">
  <element name="Trainer">
    <interleave>
      <optional>
        <element name="BatchTimeModifier">
          <ref name="nonNegativeDecimal"/>
        </element>
      </optional>
      <optional>
        <element name="Entities">
          <attribute name="datatype">
            <value>
            </value>
          </attribute>
          <text/>
        </element>
      </optional>
    </interleave>
  </element>
</define>