I created a new mod and wanted to add both a new building and a new unit. The new building shows up so I think that is working. The new unit does not show up. I checked the logs and do not see any kind of load error. I checked the Units table and do not see my new unit.
Is there a maximum number of things that can be associated to a tech? I added both my new building and unit to the HABITATION tech so I could quickly confirm they were working.
In the new unit XML I added tags for <Units>, <Unit_AITypes>, and <UnitClasses>. Are there other tables I need to add to?
Here is the definition of my new unit:
Is there a maximum number of things that can be associated to a tech? I added both my new building and unit to the HABITATION tech so I could quickly confirm they were working.
In the new unit XML I added tags for <Units>, <Unit_AITypes>, and <UnitClasses>. Are there other tables I need to add to?
Here is the definition of my new unit:
Code:
<Units>
<Row>
<Type>UNIT_NAVAL_ALIENDESTROYER</Type>
<Class>UNITCLASS_ALIENDESTROYER</Class>
<Combat>15</Combat>
<Cost>40</Cost>
<PrereqTech>TECH_HABITATION</PrereqTech>
<Description>Alien Destroyer</Description>
<Civilopedia>Attack cities</Civilopedia>
<Help>A boat that can attack cities</Help>
<Moves>5</Moves>
<CombatClass>UNITCOMBAT_NAVALMELEE</CombatClass>
<Domain>DOMAIN_SEA</Domain>
<DefaultUnitAI>UNITAI_ATTACK_SEA</DefaultUnitAI>
<MilitarySupport>true</MilitarySupport>
<MilitaryProduction>true</MilitaryProduction>
<Pillage>true</Pillage>
<IgnoreBuildingDefense>true</IgnoreBuildingDefense>
<Mechanized>true</Mechanized>
<AdvancedStartCost>40</AdvancedStartCost>
<MinAreaSize>20</MinAreaSize>
<XPValueAttack>5</XPValueAttack>
<XPValueDefense>5</XPValueDefense>
<UnitArtInfo>ART_DEF_UNIT_NAVAL_FIGHTER</UnitArtInfo>
<MoveRate>BOAT</MoveRate>
<UnitArtInfoUpgradeVariation>true</UnitArtInfoUpgradeVariation>
</Row>
</Units>
<Unit_AITypes>
<Row>
<UnitType>UNIT_NAVAL_ALIENDESTROYER</UnitType>
<UnitAIType>UNITAI_ATTACK_SEA</UnitAIType>
</Row>
<Row>
<UnitType>UNIT_NAVAL_ALIENDESTROYER</UnitType>
<UnitAIType>UNITAI_RESERVE_SEA</UnitAIType>
</Row>
<Row>
<UnitType>UNIT_NAVAL_ALIENDESTROYER</UnitType>
<UnitAIType>UNITAI_ESCORT_SEA</UnitAIType>
</Row>
<Row>
<UnitType>UNIT_NAVAL_ALIENDESTROYER</UnitType>
<UnitAIType>UNITAI_EXPLORE_SEA</UnitAIType>
</Row>
</Unit_AITypes>
<UnitClasses>
<Row>
<Type>UNIT_NAVAL_ALIENDESTROYER</Type>
<Description>Alien Destroyer</Description>
<DefaultUnit>UNIT_NAVAL_ALIENDESTROYER</DefaultUnit>
</Row>
</UnitClasses>