The Glest Wiki
(Revised)
(Added regeneration)
Line 11: Line 11:
 
<unit-type name="name" />
 
<unit-type name="name" />
 
</target>
 
</target>
<max-hp value="0" value-percent-multipler="false" />
+
<max-hp value="0" regeneration="0" value-percent-multipler="false" />
<max-ep value="0" value-percent-multipler="false" />
+
<max-ep value="0" regeneration="0" value-percent-multipler="false" />
 
<sight value="0" value-percent-multipler="false" />
 
<sight value="0" value-percent-multipler="false" />
 
<attack-strenght value="0" value-percent-multipler="false" />
 
<attack-strenght value="0" value-percent-multipler="false" />
Line 34: Line 34:
   
 
===target===
 
===target===
This tag defines who gets effected by the attack boosts. The value defines the broad characteristic, either <tt>all</tt> (any unit, regardless of alliances), <tt>ally</tt> (only allied units), <tt>foe</tt> (only opposing units), or <tt>faction</tt> (only units in the same faction).<!-- Why is "unit-types" not listed here? Because you can now have unit-type children in any of these types, it does the same thing as the "all" type, making it useless -->
+
This tag defines who gets effected by the attack boosts. The value defines the broad characteristic, either <tt>all</tt> (any unit, regardless of alliances), <tt>ally</tt> (only allied units), <tt>foe</tt> (only opposing units), or <tt>faction</tt> (only units in the same faction).
   
 
This tag can have <tt>unit-type</tt> children which can limit them down to only the listed units that fit the broader characteristic previously listed. However, it's also possible to use just these broader characteristics. For example, having just <tt>&lt;target value="ally" /&gt;</tt> allows it to effect all unit types of all allies. However, you can give it <tt>unit-type</tt> children tags to allow it to effect those types of units only if they are allies. For example, you might want it to only boost allied melee units, where you'd set the target value to ally and give a child <tt>unit-type</tt> tag to each melee unit.
 
This tag can have <tt>unit-type</tt> children which can limit them down to only the listed units that fit the broader characteristic previously listed. However, it's also possible to use just these broader characteristics. For example, having just <tt>&lt;target value="ally" /&gt;</tt> allows it to effect all unit types of all allies. However, you can give it <tt>unit-type</tt> children tags to allow it to effect those types of units only if they are allies. For example, you might want it to only boost allied melee units, where you'd set the target value to ally and give a child <tt>unit-type</tt> tag to each melee unit.
Line 41: Line 41:
   
 
===max-hp===
 
===max-hp===
How much to effect the max HP by. Negative numbers can decrease the skill. If the <tt>value-percent-multipler</tt> is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If <tt>value-percent-multipler</tt> is false, then the number is static, meaning it increases or decreases by the amount specified.
+
How much to effect the max HP by. Negative numbers can decrease the skill. If the <tt>value-percent-multipler</tt> is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If <tt>value-percent-multipler</tt> is false, then the number is static, meaning it increases or decreases by the amount specified. The <tt>regeneration</tt> attribute affects HP regeneration.
   
 
===max-ep===
 
===max-ep===
How much to effect the max EP by. Negative numbers can decrease the skill. If the <tt>value-percent-multipler</tt> is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If <tt>value-percent-multipler</tt> is false, then the number is static, meaning it increases or decreases by the amount specified. If you need to have the ability regain EP, add an optional <tt>regeneration</tt> attribute.
+
How much to effect the max EP by. Negative numbers can decrease the skill. If the <tt>value-percent-multipler</tt> is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If <tt>value-percent-multipler</tt> is false, then the number is static, meaning it increases or decreases by the amount specified. If you need to have the ability regain EP, add an optional <tt>regeneration</tt> attribute. The <tt>regeneration</tt> attribute affects EP regeneration.
   
 
===sight===
 
===sight===
Line 93: Line 93:
   
 
===Example 2===
 
===Example 2===
In this system, all nearby allied units (on the same team) within 10 tiles will have their move speed boosted by 20%. Multiple boosts will not stack (as that could result in crazy move speeds). There are no used particle effects.
+
In this system, all nearby enemy units (on a different team) within 10 tiles will have their move speed reduced by 20% (so it's 80% of the original). Multiple boosts will not stack (as that could result in extremely slow speeds). There are no used particle effects.
   
 
<syntaxhighlight lang="xml">
 
<syntaxhighlight lang="xml">
Line 99: Line 99:
 
<allow-multiple-boosts value="false" />
 
<allow-multiple-boosts value="false" />
 
<radius value="10" />
 
<radius value="10" />
<target value="ally" include-self="false" />
+
<target value="foe" include-self="false" />
 
<max-hp value="0" />
 
<max-hp value="0" />
 
<max-ep value="0" />
 
<max-ep value="0" />
Line 106: Line 106:
 
<attack-range value="0" />
 
<attack-range value="0" />
 
<armor value="0" />
 
<armor value="0" />
<move-speed value="120" value-percent-multipler="true" />
+
<move-speed value="80" value-percent-multipler="true" />
 
<production-speed value="0" />
 
<production-speed value="0" />
 
<particles value="false" />
 
<particles value="false" />

Revision as of 14:37, 20 December 2012

Attack boosts are a MegaGlest only extender which allows boosts to be applied to units in the form of emanations. Within a radius of the unit with the attack boost, other units (which can be foes, allies, a specific faction, a specific unit, or any unit) can have their stats modified and have an optional particle effect. So in other words, attack boosts provide a way to boost or detriment nearby units.

XML

<attack-boost>
	<allow-multiple-boosts value="false" />
	<radius value="5" />
	<target value="all|ally|foe|faction" include-self="false">
		<unit-type name="name" />
	</target>
	<max-hp value="0" regeneration="0" value-percent-multipler="false" />
	<max-ep value="0" regeneration="0" value-percent-multipler="false" />
	<sight value="0" value-percent-multipler="false" />
	<attack-strenght value="0" value-percent-multipler="false" />
	<attack-range value="0" value-percent-multipler="false" />
	<armor value="0" value-percent-multipler="false" />
	<move-speed value="0" value-percent-multipler="false" />
	<production-speed value="0" value-percent-multipler="false" />
	<particles value="true">
		<originator-particle-file path="glow_particles.xml" />
		<affected-particle-file path="glow_particles.xml" />
	</particles>
</attack-boost>

Documentation

allow-multiple-boosts

If true, there can be multiple boosts, which will stack. If false, boosts cannot stack, but will simply overwrite.

radius

The maximum distance from the attacking unit from which the attack-boost will take effect.

target

This tag defines who gets effected by the attack boosts. The value defines the broad characteristic, either all (any unit, regardless of alliances), ally (only allied units), foe (only opposing units), or faction (only units in the same faction).

This tag can have unit-type children which can limit them down to only the listed units that fit the broader characteristic previously listed. However, it's also possible to use just these broader characteristics. For example, having just <target value="ally" /> allows it to effect all unit types of all allies. However, you can give it unit-type children tags to allow it to effect those types of units only if they are allies. For example, you might want it to only boost allied melee units, where you'd set the target value to ally and give a child unit-type tag to each melee unit.

The include-self tag defines whether or not the unit with the attack boost should be included as a target.

max-hp

How much to effect the max HP by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified. The regeneration attribute affects HP regeneration.

max-ep

How much to effect the max EP by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified. If you need to have the ability regain EP, add an optional regeneration attribute. The regeneration attribute affects EP regeneration.

sight

How much to effect the sight by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified.

attack-strenght

How much to effect the attack strength by (note the necessary misspelling of the tag). Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified.

attack-range

How much to effect the attack range by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified.

armor

How much to effect the armor by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified.

move-speed

How much to effect the move speed by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified.

production-speed

How much to effect the production speed (produce/morph/upgrade) by. Negative numbers can decrease the skill. If the value-percent-multipler is true, the number is a percentage (where 100 is the same as no multiplier, 200 is the same as a doubling the stat, and 50 is the same as halving the stat). If value-percent-multipler is false, then the number is static, meaning it increases or decreases by the amount specified.

Particles

It's also possible to apply particle systems to the attacker and/or the affected units. These tags are optional. The attack can be given a particle system with the originator-particle-file tag, while the affected units can be given one with the affected-particle-file tag. The originator particle effect only occurs if the attack boost is being used (it must be affecting at least one unit, which can include the user if include-self is set to true.

Examples

Example 1

In this example, all swordmen in the same faction within a five cell radius of the attacking unit will gain 10% more HP and +20 attack. The affected units will all have the particle system defined in the glow_particles.xml file applied to them.

<attack-boost>
	<allow-multiple-boosts value="false" />
	<radius value="5"/>
	<target value="faction">
		<unit-type name="swordman" />
	</target>
	<max-hp value="110" value-percent-multipler="true" />
	<max-ep value="0"/>
	<sight value="0"/>
	<attack-strenght value="20"/>
	<attack-range value="0"/>
	<armor value="0"/>
	<move-speed value="0" />
	<production-speed value="0"/>
	<particles value="true">
		<affected-particle-file path="glow_particles.xml"/>
	</particles>
</attack-boost>

Example 2

In this system, all nearby enemy units (on a different team) within 10 tiles will have their move speed reduced by 20% (so it's 80% of the original). Multiple boosts will not stack (as that could result in extremely slow speeds). There are no used particle effects.

<attack-boost>
	<allow-multiple-boosts value="false" />
	<radius value="10" />
	<target value="foe" include-self="false" />
	<max-hp value="0" />
	<max-ep value="0" />
	<sight value="0" />
	<attack-strenght value="0" />
	<attack-range value="0" />
	<armor value="0" />
	<move-speed value="80" value-percent-multipler="true" />
	<production-speed value="0" />
	<particles value="false" />
</attack-boost>

See also