Skip to content

Target property

INI referenceEnumsTargetPropertyType

Selection rules used when a team script picks one building from all those of a named type.

Engine enum
TargetPropertyType
Input form
Integer

The declared enemy of the team’s house comes first. The mission picks that house’s best-rated structure, however the property rates structures of other houses. Another house’s structure is picked only when the declared enemy has none of the named type. Attack enemy building covers which houses qualify.

Values 0 and 1 rank candidates by the threat map of the team’s house. That map holds one figure for each region, a block of 4 by 4 cells, and each candidate is rated by the figure for the region that holds its center cell. The candidate’s own ThreatPosed is one contribution to that figure; its strength and cost play no part.

A region’s figure also counts objects outside it, because each object’s ThreatPosed raises the regions around its own as well. Ownership, alliances and map rebuilds decide which objects count at all. The threat map describes both.

A value outside 0 to 3 gives every candidate the same rating, so the mission picks no structure.

Values

4 of 4

InputMeaningEngine constantStored value
0Pick the candidate in the region with the lowest figure on the threat map of the team's house.TPROPERTY_LEAST_THREAT0
1Pick the candidate in the region with the highest figure on the threat map of the team's house.TPROPERTY_GREATEST_THREAT1
2Pick the candidate nearest the team member that joined the team most recently.TPROPERTY_NEAREST2
3Pick the candidate farthest from the team member that joined the team most recently.TPROPERTY_FARTHEST3

Used by

Source files

Linked at revision 51b52aa38392.