Resource icon

Vincentz Rangestrike 2016-10-05

Updated 5/5-2016!

This mod adds Rangestrikes (Ranged Combat) to sieges and ships from Frigate and forward. The sieges are no longer able to perform direct combat, only rangestrikes. The ships can do both. AI will use it for Land2Land, Land2Sea, Sea2Land, Continent2Continent and sometimes Sea2Sea.

The formula for hit chance is depending on airdamage, enemy strength and how many enemy units on plot.

Thread for bugreports and suggestions

rangestrike_9LD.png


When a rangestrike is made and a defender with rangestrike is being targeted, it will automatically return fire. To make sure its the rangestriker that defends, the <UnitCombatDefenders> can be used on the rangestrikers in the CIV4UnitInfos.xml. Otherwise it will be the strongest defender that will be hit.
Code:
<UnitCombatDefenders>
	<UnitCombatDefender>
		<UnitCombatDefenderType>UNITCOMBAT_SIEGE</UnitCombatDefenderType>
		<bUnitCombatDefender>1</bUnitCombatDefender>
	</UnitCombatDefender>
</UnitCombatDefenders>

To enable rangestrike for a unit, 3 things have to be changed in the CIV4UnitInfos.XML :
1) <iAirRange>
the range the unit can hit
2) <iAirCombat>
the damage done by an attack (Random 1-100%)
3) <iAirCombatLimit>
the max % of damage possible to enemy unit

The RANGE_COMBAT_DAMAGE in GlobalDefines.xml can be used to adjust the overall damage done by rangestrikes.

Note: Messaging is not completely done, and will be adjusted in later version.

Special thanks to everyone who helped with the coding. :goodjob:
  • rangestrike2_qn7.png
    rangestrike2_qn7.png
    81.4 KB · Views: 320
  • rangestrike_9LD.png
    rangestrike_9LD.png
    780.4 KB · Views: 340
Author
vincentz
Downloads
449
Views
823
First release
Last update

Ratings

0.00 star(s) 0 ratings

More resources from vincentz

Back
Top Bottom