does it possible the 3 unique unit

Yes it is possible, but I don't have the files near me to tell you how. Maybe somebody else can chime in?
 
To add more unique units (pretty much unlimited number as far as I understand), you need to create a new unit of an already existing class, like for example UNITCLASS_KNIGHT, of course it should have its own type, e.g. UNIT_SAMURAI_KNIGHT. Then in Civ4Civilizations_Info.xml file (I might've gotten the name of the file a bit off as I don't have it in front of me) you need to find whatever civ you want to add the new unique unit to, and find an entry that defines a unique unit, copy it and change it to the new unit you made. I don't remember how the entry looks but just look for a known unique unit.
 
It looks like this...

Code:
<Units>
	<Unit>
		<UnitClassType>UNITCLASS_MARINE</UnitClassType>
		<UnitType>UNIT_AMERICAN_NAVY_SEAL</UnitType>
	</Unit>
</Units>

Now making a change...

Code:
<Units>
	<Unit>
		<UnitClassType>UNITCLASS_MARINE</UnitClassType>
		<UnitType>UNIT_AMERICAN_NAVY_SEAL</UnitType>
	</Unit>
[b]	<Unit>
		<UnitClassType>UNITCLASS_SETTLER</UnitClassType>
		<UnitType>UNIT_AMERICAN_SUPER_SETTLER</UnitType>
	</Unit>[/b]
</Units>

Of course, this assumes that I've made changes in the CIV4UnitInfos.xml files and added a "UNIT_AMERICAN_SUPER_SETTLER" unit. Now the Americans have two unique units: The Navy Seal, and the Super Settler.
 
I change in
-civilizationinfos.xml
-in globaldefines the number of golden age unit from 2 to 3 and later to -1
-i do this same info class unit that Rabbit say

it doesnt works:(
 
Shade_89 said:
I change in
-civilizationinfos.xml
-in globaldefines the number of golden age unit from 2 to 3 and later to -1
-i do this same info class unit that Rabbit say

it doesnt works:(

We are going to need some more info on what you did / what's going wrong.

For starters, perhaps put exactly what lines of the xml files you modified/added. Then, tell what errors you're getting (if any) or what is not happening that is expected to happen.
 
i changed this:
in CIV4CivilizationInfos.xml

<Units>
<Unit>
<UnitClassType>UNITCLASS_HORSE_ARCHER</UnitClassType>
<UnitType>UNIT_ARABIA_CAMELARCHER</UnitType>
</Unit>
<Unit>
<UnitClassType>UNITCLASS_KNIGHT</UnitClassType>
<UnitType>UNIT_ARABIA_ANSAR</UnitType>
</Unit>
<Unit>
<UnitClassType>UNITCLASS_MUJAHID</UnitClassType>
<UnitType>UNIT_ARABIA_MUJAHID</UnitType>
</Unit>
</Units>




IN CIV 4UNITINFOS.XML

<UnitInfo>
<Class>UNITCLASS_MUJAHID</Class>
<Type>UNIT_ARABIA_MUJAHID</Type>
<UniqueNames/>
<Special>NONE</Special>
<Capture>NONE</Capture>
<Combat>UNITCOMBAT_MOUNTED</Combat>
<Domain>DOMAIN_LAND</Domain>
<DefaultUnitAI>UNITAI_ATTACK</DefaultUnitAI>
<Invisible>NONE</Invisible>
<SeeInvisible>NONE</SeeInvisible>
<Description>TXT_KEY_UNIT_MUJAHID</Description>
<Civilopedia>TXT_KEY_UNIT_MUJAHID_PEDIA</Civilopedia>
<Strategy>TXT_KEY_UNIT_MUJAHID_STRATEGY</Strategy>
<Advisor>ADVISOR_MILITARY</Advisor>
<bAnimal>0</bAnimal>
<bFood>0</bFood>
<bNoBadGoodies>0</bNoBadGoodies>
<bOnlyDefensive>0</bOnlyDefensive>
<bNoCapture>0</bNoCapture>
<bRivalTerritory>0</bRivalTerritory>
<bMilitaryHappiness>1</bMilitaryHappiness>
<bMilitarySupport>1</bMilitarySupport>
<bMilitaryProduction>1</bMilitaryProduction>
<bPillage>1</bPillage>
<bSabotage>0</bSabotage>
<bDestroy>0</bDestroy>
<bStealPlans>0</bStealPlans>
<bInvestigate>0</bInvestigate>
<bCounterSpy>0</bCounterSpy>
<bFound>0</bFound>
<bGoldenAge>0</bGoldenAge>
<bInvisible>0</bInvisible>
<bFirstStrikeImmune>0</bFirstStrikeImmune>
<bNoDefensiveBonus>0</bNoDefensiveBonus>
<bIgnoreBuildingDefense>0</bIgnoreBuildingDefense>
<bCanMoveImpassable>0</bCanMoveImpassable>
<bFlatMovementCost>0</bFlatMovementCost>
<bIgnoreTerrainCost>0</bIgnoreTerrainCost>
<bNukeImmune>0</bNukeImmune>
<bPrereqBonuses>0</bPrereqBonuses>
<bPrereqReligion>0</bPrereqReligion>
<bMechanized>0</bMechanized>
<UnitClassUpgrades/>
<UnitAIs>
<UnitAI>
<UnitAIType>UNITAI_ATTACK</UnitAIType>
<bUnitAI>1</bUnitAI>
</UnitAI>
<UnitAI>
<UnitAIType>UNITAI_PILLAGE</UnitAIType>
<bUnitAI>1</bUnitAI>
</UnitAI>
</UnitAIs>
<NotUnitAIs>
<UnitAI>
<UnitAIType>UNITAI_CITY_COUNTER</UnitAIType>
<bUnitAI>1</bUnitAI>
</UnitAI>
</NotUnitAIs>
<Builds/>
<ReligionSpreads/>
<GreatPeoples/>
<Buildings/>
<ForceBuildings/>
<HolyCity>NONE</HolyCity>
<ReligionType>NONE</ReligionType>
<StateReligion>NONE</StateReligion>
<PrereqReligion>NONE</PrereqReligion>
<PrereqBuilding>NONE</PrereqBuilding>
<PrereqTech>TECH_FEUDALISM</PrereqTech>
<TechTypes/>
<BonusType>BONUS_HORSE</BonusType>
<PrereqBonuses/>
<ProductionTraits/>
<Flavors/>
<iAIWeight>0</iAIWeight>
<iCost>45</iCost>
<iHurryCostModifier>0</iHurryCostModifier>
<iMinAreaSize>-1</iMinAreaSize>
<iMoves>2</iMoves>
<iAirRange>0</iAirRange>
<iNukeRange>-1</iNukeRange>
<iWorkRate>0</iWorkRate>
<iBaseDiscover>0</iBaseDiscover>
<iDiscoverMultiplier>0</iDiscoverMultiplier>
<iBaseHurry>0</iBaseHurry>
<iHurryMultiplier>0</iHurryMultiplier>
<iBaseTrade>0</iBaseTrade>
<iTradeMultiplier>0</iTradeMultiplier>
<iGreatWorkCulture>0</iGreatWorkCulture>
<TerrainImpassables/>
<FeatureImpassables/>
<iCombat>10</iCombat>
<iAirCombat>0</iAirCombat>
<iAirCombatLimit>0</iAirCombatLimit>
<iXPValueAttack>4</iXPValueAttack>
<iXPValueDefense>2</iXPValueDefense>
<iFirstStrikes>0</iFirstStrikes>
<iChanceFirstStrikes>0</iChanceFirstStrikes>
<iInterceptionProbability>0</iInterceptionProbability>
<iEvasionProbability>0</iEvasionProbability>
<iWithdrawalProb>0</iWithdrawalProb>
<iCollateralDamage>0</iCollateralDamage>
<iCollateralDamageLimit>0</iCollateralDamageLimit>
<iCollateralDamageMaxUnits>0</iCollateralDamageMaxUnits>
<iCityAttack>0</iCityAttack>
<iCityDefense>0</iCityDefense>
<iAnimalCombat>0</iAnimalCombat>
<iHillsDefense>0</iHillsDefense>
<TerrainNatives/>
<FeatureNatives/>
<TerrainDefenses/>
<FeatureDefenses/>
<UnitClassAttackMods/>
<UnitClassDefenseMods/>
<UnitCombatMods>
<UnitCombatMod>
<UnitCombatType>UNITCOMBAT_MELEE</UnitCombatType>
<iUnitCombatMod>25</iUnitCombatMod>
</UnitCombatMod>
</UnitCombatMods>
<DomainMods/>
<BonusProductionModifiers/>
<iBombRate>0</iBombRate>
<iBombardRate>0</iBombardRate>
<SpecialCargo>NONE</SpecialCargo>
<DomainCargo>NONE</DomainCargo>
<iCargo>0</iCargo>
<iConscription>0</iConscription>
<iCultureGarrison>4</iCultureGarrison>
<iExtraCost>0</iExtraCost>
<iAsset>1</iAsset>
<iPower>3</iPower>
<UnitMeshGroups>
<iGroupSize>3</iGroupSize>
<fMaxSpeed>1.75</fMaxSpeed>
<iMeleeWaveSize>3</iMeleeWaveSize>
<iRangedWaveSize>0</iRangedWaveSize>
<UnitMeshGroup>
<iRequired>3</iRequired>
<EarlyArtDefineTag>ART_DEF_UNIT_MUJAHID</EarlyArtDefineTag>
</UnitMeshGroup>
</UnitMeshGroups>
<Button>Art/Interface/Buttons/Units/mujahid.dds</Button>
<HotKey/>
<bAltDown>0</bAltDown>
<bShiftDown>0</bShiftDown>
<bCtrlDown>0</bCtrlDown>
<iHotKeyPriority>0</iHotKeyPriority>
<FreePromotions></FreePromotions>
</UnitInfo>



unitclassinfos.xml

<UnitClassInfo>
<Type>UNITCLASS_MUJAHID</Type>
<Description>TXT_KEY_UNIT_ARABIA_MUJAHID</Description>
<iMaxGlobalInstances>-1</iMaxGlobalInstances>
<iMaxTeamInstances>-1</iMaxTeamInstances>
<iMaxPlayerInstances>-1</iMaxPlayerInstances>
<DefaultUnit>UNIT_ARABIA_MUJAHID</DefaultUnit>
</UnitClassInfo>

This 3rd unique ARABIA unit MUJAHID doesn't is a unique unit but normal unit for all civs
 
That is because you created it as a new class. All unique units must be of an already existing class, so in your case MUJAHID should be the same class as, well not sure what, but something. Just like the previous two units, notice that they use an existing class, not their own class. This is because you're essentially saying "replace this [already existing unit] with the unique unit". What you did by creating a class for your unit, is say "replace this new unit with the same new unique unit", see the problem. :)

Btw, if you want Mujahid to also replace the knight that'd be an interesting experiment, I don't know if it's possible to have two UUs that replace one unit.

Also, this "-in globaldefines the number of golden age unit from 2 to 3 and later to -1", you don't need to do that. This simply determines how many great people units you need to combine to go into golden age.
 
thanks it is working with different class than Mujahid
also I changed like you proposed his class to knight i I have 2 UU that have this same class and one is working another doesn't
 
If you want to make an entire CLASS unique to one Civ, that's a lot more tedious: creat the new class as you did already, but for all OTHER Civs (not the one that gets the UU), set it to:
HTML:
<Unit>
   <UnitClassType>UNITCLASS_MUJAHID</UnitClassType>
   <UnitType>NONE</UnitType>
</Unit>
See the Barbarian Civ for examples (they are not allowed to use all sorts of units). You'll have to do this for EVERY civ that doesn't get this "Unique Class."

Otherwise, a UU has to REPLACE a conventional unit.
 
Padmewan said:
If you want to make an entire CLASS unique to one Civ, that's a lot more tedious: creat the new class as you did already, but for all OTHER Civs (not the one that gets the UU), set it to:
...
...

Otherwise, a UU has to REPLACE a conventional unit.

Or you could just make the default unit for your new class NONE. That makes everyone unable to build it unless specified otherwise.
 
snarko said:
Or you could just make the default unit for your new class NONE. That makes everyone unable to build it unless specified otherwise.
Aha! Sharp thinking. :goodjob:
 
snarko said:
Or you could just make the default unit for your new class NONE. That makes everyone unable to build it unless specified otherwise.

I assume you mean in the unitclassinfo file?

as in :

<UnitClassInfo>
<Type>UNITCLASS_MUJAHID</Type>
<Description>TXT_KEY_UNIT_ARABIA_MUJAHID</Description>
<iMaxGlobalInstances>-1</iMaxGlobalInstances>
<iMaxTeamInstances>-1</iMaxTeamInstances>
<iMaxPlayerInstances>-1</iMaxPlayerInstances>
<DefaultUnit>NONE</DefaultUnit>
</UnitClassInfo>

yes?

Cheers!
 
BlazeRedSXT said:
I assume you mean in the unitclassinfo file?

as in :
...
Yes that's what I mean.
 
Back
Top Bottom