I'm creating a small, one unit mod which *hopefully* adds a version of the helicopter gunship which can carry guided missiles (hopefully means it will probably carry nukes, too, though I'd rather it didn't). The logic behind this is as a sort of mobile missile launcher for terrestrial civs, especially those that aren't capable of launching a missile anywhere on the map (OCC's, for example).
This is the code for the Helicopter Gunship:
And this is the code for my MA Helicopter:
Any tips/suggestions? I currently can't get it to run ingame, if anyone can figure out whats wrong, I'd appreciate the information.
For those who don't want to sort through the code,
Helicopter gunship: 50 combat, 500 cost
MA Helicopter: 30 combat, 400 cost, can carry missiles.
The missile code was taken from the Missile Cruiser.
This is the code for the Helicopter Gunship:
Spoiler :
<Row>
<Class>UNITCLASS_HELICOPTER_GUNSHIP</Class>
<Type>UNIT_HELICOPTER_GUNSHIP</Type>
<PrereqTech>TECH_ROCKETRY</PrereqTech>
<Combat>50</Combat>
<Cost>500</Cost>
<Moves>6</Moves>
<CombatClass>UNITCOMBAT_HELICOPTER</CombatClass>
<Domain>DOMAIN_LAND</Domain>
<DefaultUnitAI>UNITAI_FAST_ATTACK</DefaultUnitAI>
<Description>TXT_KEY_UNIT_HELICOPTER_GUNSHIP</Description>
<Civilopedia>TXT_KEY_CIVILOPEDIA_UNITS_MODERN_HELICOPTERGUNSHIP_TEXT</Civilopedia>
<Strategy>TXT_KEY_UNIT_HELICOPTER_GUNSHIP_STRATEGY</Strategy>
<Help>TXT_KEY_UNIT_HELP_HELICOPTER_GUNSHIP</Help>
<MilitarySupport>true</MilitarySupport>
<MilitaryProduction>true</MilitaryProduction>
<Pillage>true</Pillage>
<IgnoreBuildingDefense>true</IgnoreBuildingDefense>
<AdvancedStartCost>60</AdvancedStartCost>
<XPValueAttack>3</XPValueAttack>
<XPValueDefense>3</XPValueDefense>
<UnitArtInfo>ART_DEF_UNIT_HELICOPTER_GUNSHIP</UnitArtInfo>
<UnitFlagIconOffset>75</UnitFlagIconOffset>
<IconAtlas>UNIT_ATLAS_2</IconAtlas>
<PortraitIndex>28</PortraitIndex>
<MoveRate>WHEELED</MoveRate>
</Row>
<Class>UNITCLASS_HELICOPTER_GUNSHIP</Class>
<Type>UNIT_HELICOPTER_GUNSHIP</Type>
<PrereqTech>TECH_ROCKETRY</PrereqTech>
<Combat>50</Combat>
<Cost>500</Cost>
<Moves>6</Moves>
<CombatClass>UNITCOMBAT_HELICOPTER</CombatClass>
<Domain>DOMAIN_LAND</Domain>
<DefaultUnitAI>UNITAI_FAST_ATTACK</DefaultUnitAI>
<Description>TXT_KEY_UNIT_HELICOPTER_GUNSHIP</Description>
<Civilopedia>TXT_KEY_CIVILOPEDIA_UNITS_MODERN_HELICOPTERGUNSHIP_TEXT</Civilopedia>
<Strategy>TXT_KEY_UNIT_HELICOPTER_GUNSHIP_STRATEGY</Strategy>
<Help>TXT_KEY_UNIT_HELP_HELICOPTER_GUNSHIP</Help>
<MilitarySupport>true</MilitarySupport>
<MilitaryProduction>true</MilitaryProduction>
<Pillage>true</Pillage>
<IgnoreBuildingDefense>true</IgnoreBuildingDefense>
<AdvancedStartCost>60</AdvancedStartCost>
<XPValueAttack>3</XPValueAttack>
<XPValueDefense>3</XPValueDefense>
<UnitArtInfo>ART_DEF_UNIT_HELICOPTER_GUNSHIP</UnitArtInfo>
<UnitFlagIconOffset>75</UnitFlagIconOffset>
<IconAtlas>UNIT_ATLAS_2</IconAtlas>
<PortraitIndex>28</PortraitIndex>
<MoveRate>WHEELED</MoveRate>
</Row>
And this is the code for my MA Helicopter:
Spoiler :
<GameData>
<Row>
<Class>UNITCLASS_HELICOPTER_GUNSHIP</Class>
<Type>UNIT_MA_HELICOPTER</Type>
<PrereqTech>TECH_ROCKETRY</PrereqTech>
<Combat>30</Combat>
<Cost>400</Cost>
<Moves>6</Moves>
<CombatClass>UNITCOMBAT_HELICOPTER</CombatClass>
<Domain>DOMAIN_LAND</Domain>
<DefaultUnitAI>UNITAI_FAST_ATTACK</DefaultUnitAI>
<Description>TXT_KEY_UNIT_MA_HELICOPTER</Description>
<Civilopedia>TXT_KEY_CIVILOPEDIA_UNITS_MODERN_HELICOPTERGUNSHIP_TEXT</Civilopedia>
<Strategy>TXT_KEY_UNIT_HELICOPTER_GUNSHIP_STRATEGY</Strategy>
<Help>TXT_KEY_UNIT_HELP_HELICOPTER_GUNSHIP</Help>
<MilitarySupport>true</MilitarySupport>
<MilitaryProduction>true</MilitaryProduction>
<Pillage>true</Pillage>
<IgnoreBuildingDefense>true</IgnoreBuildingDefense>
<AdvancedStartCost>60</AdvancedStartCost>
<XPValueAttack>3</XPValueAttack>
<XPValueDefense>3</XPValueDefense>
<SpecialCargo>SPECIALUNIT_MISSILE</SpecialCargo>
<DomainCargo>DOMAIN_AIR</DomainCargo>
<UnitArtInfo>ART_DEF_UNIT_HELICOPTER_GUNSHIP</UnitArtInfo>
<UnitFlagIconOffset>75</UnitFlagIconOffset>
<IconAtlas>UNIT_ATLAS_2</IconAtlas>
<PortraitIndex>28</PortraitIndex>
<MoveRate>WHEELED</MoveRate>
</Row>
</GameData>
<Row>
<Class>UNITCLASS_HELICOPTER_GUNSHIP</Class>
<Type>UNIT_MA_HELICOPTER</Type>
<PrereqTech>TECH_ROCKETRY</PrereqTech>
<Combat>30</Combat>
<Cost>400</Cost>
<Moves>6</Moves>
<CombatClass>UNITCOMBAT_HELICOPTER</CombatClass>
<Domain>DOMAIN_LAND</Domain>
<DefaultUnitAI>UNITAI_FAST_ATTACK</DefaultUnitAI>
<Description>TXT_KEY_UNIT_MA_HELICOPTER</Description>
<Civilopedia>TXT_KEY_CIVILOPEDIA_UNITS_MODERN_HELICOPTERGUNSHIP_TEXT</Civilopedia>
<Strategy>TXT_KEY_UNIT_HELICOPTER_GUNSHIP_STRATEGY</Strategy>
<Help>TXT_KEY_UNIT_HELP_HELICOPTER_GUNSHIP</Help>
<MilitarySupport>true</MilitarySupport>
<MilitaryProduction>true</MilitaryProduction>
<Pillage>true</Pillage>
<IgnoreBuildingDefense>true</IgnoreBuildingDefense>
<AdvancedStartCost>60</AdvancedStartCost>
<XPValueAttack>3</XPValueAttack>
<XPValueDefense>3</XPValueDefense>
<SpecialCargo>SPECIALUNIT_MISSILE</SpecialCargo>
<DomainCargo>DOMAIN_AIR</DomainCargo>
<UnitArtInfo>ART_DEF_UNIT_HELICOPTER_GUNSHIP</UnitArtInfo>
<UnitFlagIconOffset>75</UnitFlagIconOffset>
<IconAtlas>UNIT_ATLAS_2</IconAtlas>
<PortraitIndex>28</PortraitIndex>
<MoveRate>WHEELED</MoveRate>
</Row>
</GameData>
Any tips/suggestions? I currently can't get it to run ingame, if anyone can figure out whats wrong, I'd appreciate the information.
For those who don't want to sort through the code,
Helicopter gunship: 50 combat, 500 cost
MA Helicopter: 30 combat, 400 cost, can carry missiles.
The missile code was taken from the Missile Cruiser.