ResourceGatherer¶
Examples¶
Example¶
<ResourceGatherer>
<MaxDistance>
2.0
</MaxDistance>
<BaseSpeed>
1.0
</BaseSpeed>
<Rates>
<food.fish>
1
</food.fish>
<metal.ore>
3
</metal.ore>
<stone.rock>
3
</stone.rock>
<wood.tree>
2
</wood.tree>
</Rates>
<Capacities>
<food>
10
</food>
<metal>
10
</metal>
<stone>
10
</stone>
<wood>
10
</wood>
</Capacities>
</ResourceGatherer>
XML Elements¶
The following elements can be used within this component:
ResourceGatherer¶
MaxDistance¶
Max resource-gathering distance
Type: positive decimal
Path: ResourceGatherer/MaxDistance
BaseSpeed¶
Base resource-gathering rate (in resource units per second)
Type: positive decimal
Path: ResourceGatherer/BaseSpeed
Rates¶
Per-resource-type gather rate multipliers. If a resource type is not specified then it cannot be gathered by this unit
Path: ResourceGatherer/Rates
food¶
Type: positive decimal
Path: ResourceGatherer/Rates/food
wood¶
Type: positive decimal
Path: ResourceGatherer/Rates/wood
stone¶
Type: positive decimal
Path: ResourceGatherer/Rates/stone
metal¶
Type: positive decimal
Path: ResourceGatherer/Rates/metal
food.fish¶
Type: positive decimal
Path: ResourceGatherer/Rates/food.fish
food.fruit¶
Type: positive decimal
Path: ResourceGatherer/Rates/food.fruit
food.grain¶
Type: positive decimal
Path: ResourceGatherer/Rates/food.grain
food.meat¶
Type: positive decimal
Path: ResourceGatherer/Rates/food.meat
wood.tree¶
Type: positive decimal
Path: ResourceGatherer/Rates/wood.tree
wood.ruins¶
Type: positive decimal
Path: ResourceGatherer/Rates/wood.ruins
stone.rock¶
Type: positive decimal
Path: ResourceGatherer/Rates/stone.rock
stone.ruins¶
Type: positive decimal
Path: ResourceGatherer/Rates/stone.ruins
metal.ore¶
Type: positive decimal
Path: ResourceGatherer/Rates/metal.ore
metal.ruins¶
Type: positive decimal
Path: ResourceGatherer/Rates/metal.ruins
Capacities¶
Per-resource-type maximum carrying capacity
Path: ResourceGatherer/Capacities
food¶
Type: positive decimal
Path: ResourceGatherer/Capacities/food
wood¶
Type: positive decimal
Path: ResourceGatherer/Capacities/wood
stone¶
Type: positive decimal
Path: ResourceGatherer/Capacities/stone
metal¶
Type: positive decimal
Path: ResourceGatherer/Capacities/metal
RELAX NG Grammar¶
<define name="component.ResourceGatherer">
<element name="ResourceGatherer">
<interleave>
<element name="MaxDistance">
<ref name="positiveDecimal"/>
</element>
<element name="BaseSpeed">
<ref name="positiveDecimal"/>
</element>
<element name="Rates">
<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>
<optional>
<element name="food.fish">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="food.fruit">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="food.grain">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="food.meat">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="wood.tree">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="wood.ruins">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="stone.rock">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="stone.ruins">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="metal.ore">
<ref name="positiveDecimal"/>
</element>
</optional>
<optional>
<element name="metal.ruins">
<ref name="positiveDecimal"/>
</element>
</optional>
</interleave>
</element>
<element name="Capacities">
<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>
</interleave>
</element>
</define>