Replace UU of Existing Civ

yellowdartfrog

Chieftain
Joined
Nov 8, 2010
Messages
17
Does anyone know how I replace a civilization's unique unit with my own UU? I am trying to create an 'SAS' unit (paratrooper) for England but it doesn't work.

First I tried the following but it removed their use of both the Ship of the Line and the Frigate:

Code:
<GameData>
	<Civilization_UnitClassOverrides>
		<Row>
			<CivilizationType>CIVILIZATION_ENGLAND</CivilizationType>
			<UnitClassType>UNITCLASS_PARATROOPER</UnitClassType>
			<UnitType>UNIT_ENGLISH_SAS</UnitType>
		</Row>
		<Update>
			<Set UnitType="" />
			<Where CivilizationType="CIVILIZATION_ENGLAND" UnitClassType="UNITCLASS_FRIGATE"></Where>
		</Update>
	</Civilization_UnitClassOverrides>
</GameData>

And then I tried this but it chose the Frigate as their second unique unit!! Obviously this is better than the first situation because the can use the Frigate and have the SAS as their second UU but I would prefer it to show up when you choose the Civ.

Code:
<GameData>
	<Civilization_UnitClassOverrides>
		<Row>
			<CivilizationType>CIVILIZATION_ENGLAND</CivilizationType>
			<UnitClassType>UNITCLASS_PARATROOPER</UnitClassType>
			<UnitType>UNIT_ENGLISH_SAS</UnitType>
		</Row>
		<Update>
			<Set UnitType="UNIT_FRIGATE"/>
			<Where CivilizationType="CIVILIZATION_ENGLAND" UnitClassType="UNITCLASS_FRIGATE"></Where>
		</Update>
	</Civilization_UnitClassOverrides>
</GameData>

Can anyone please propose an alternative? Thanks!
 
Does anyone know how I replace a civilization's unique unit with my own UU? I am trying to create an 'SAS' unit (paratrooper) for England but it doesn't work.

First I tried the following but it removed their use of both the Ship of the Line and the Frigate:

Code:
<GameData>
	<Civilization_UnitClassOverrides>
		<Row>
			<CivilizationType>CIVILIZATION_ENGLAND</CivilizationType>
			<UnitClassType>UNITCLASS_PARATROOPER</UnitClassType>
			<UnitType>UNIT_ENGLISH_SAS</UnitType>
		</Row>
		<Update>
			<Set UnitType="" />
			<Where CivilizationType="CIVILIZATION_ENGLAND" UnitClassType="UNITCLASS_FRIGATE"></Where>
		</Update>
	</Civilization_UnitClassOverrides>
</GameData>

And then I tried this but it chose the Frigate as their second unique unit!! Obviously this is better than the first situation because the can use the Frigate and have the SAS as their second UU but I would prefer it to show up when you choose the Civ.

Code:
<GameData>
	<Civilization_UnitClassOverrides>
		<Row>
			<CivilizationType>CIVILIZATION_ENGLAND</CivilizationType>
			<UnitClassType>UNITCLASS_PARATROOPER</UnitClassType>
			<UnitType>UNIT_ENGLISH_SAS</UnitType>
		</Row>
		<Update>
			<Set UnitType="UNIT_FRIGATE"/>
			<Where CivilizationType="CIVILIZATION_ENGLAND" UnitClassType="UNITCLASS_FRIGATE"></Where>
		</Update>
	</Civilization_UnitClassOverrides>
</GameData>

Can anyone please propose an alternative? Thanks!

Maybe try making the update for <UnitClassType> instead of <UnitType>. Update it to "", like you did the first time.

So:
<Update>
<Set UnitClassType="" />
<Where CivilizationType="CIVILIZATION_ENGLAND" UnitType="UNIT_ENGLISH_SHIPOFTHELINE"></Where>
</Update>

Not exactly sure what they use for ship of the line btw. Just a guess.
 
Does anyone know how I replace a civilization's unique unit with my own UU? I am trying to create an 'SAS' unit (paratrooper) for England but it doesn't work.

Your first attempt, changed the "for England, replace Frigate with a Ship of the Line" to "for England, replace Frigate with Nothing" - hence why you "lost" both units.

Your second attempt added the SAS unit, but as you didn't delete the Ship of the Line replacement that still shows as the second UU (civs can have more than two UB's and UU's, but the interface only displays the first two)

What you need to do is delete the "frigate to ship of the line" database entry

Code:
<Delete CivilizationType="CIVILIZATION_ENGLAND" UnitClassType="UNITCLASS_FRIGATE"/>

(or some such - typing from memory is such a bad idea!)

HTH

W
 
Back
Top Bottom