| General | Hosted Sites | Civ5 | CivRev | Civ4Col | Civ4 | Civ3 | Civ2 | Civ1 | Misc | Marketplace |
![]() |
|
|
Welcome to Civilization Fanatics' Center. You are currently viewing our site as a guest which gives you limited access to our site features. By joining our free community, you will be able to participate in the discussions, search the forum, send private messages, vote in polls, upload your own screenshots to the gallery, and access many other special features. Registration is fast, simple and absolutely free, so sign up today! If you have any problems with the registration process or your account login, please contact support. |
|
|||||||
![]() |
|
|
Thread Tools |
|
|
#1 |
|
Chieftain
Join Date: Jun 2008
Posts: 11
|
My question, I know to modify most things you do so in the XML files and I have been able to modify a few things such as the default color of certain civilizations, move points but what I can't figure out is how to make an existing unit specific to only 1 civilization and how do you change the units you start out with, both the kind of units and how many?
Thanks AlleyGator
|
|
|
|
|
|
#2 |
|
Emperor
Join Date: Sep 2005
Location: a puddle
Posts: 1,206
|
Both are in: CIV4CivilizationInfos.xml
UU maybe not be so simple, it depends on the classes: Code:
<Unit> <UnitClassType>UNITCLASS_PRAESIDIUM</UnitClassType> <UnitType>UNIT_ROMAN_PRAESIDIUM</UnitType> </Unit> Another way to make a unit buildable by only 1 civ is to require a unique tech, and have that tech enable the unit. |
|
|
|
|
|
#3 |
|
Deity
![]() Join Date: Apr 2006
Location: New York State
Posts: 4,859
|
Actually, no need to use the tech for that. In Civ4UnitClassInfos:
Code:
<UnitClassInfo> <Type>UNITCLASS_STARBASE_I</Type> <Description>TXT_KEY_UNIT_STARBASE_I</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>-1</iMaxPlayerInstances> <iInstanceCostModifier>0</iInstanceCostModifier> <DefaultUnit>UNIT_STARBASE_I</DefaultUnit> </UnitClassInfo>
__________________
Mods: Convert Production to Espionage, FinalFronterFlat, The Road to War Ultimate Edition for BtS 3.19, Star Trek |
|
|
|
|
|
#4 |
|
Chieftain
Join Date: Jun 2008
Posts: 11
|
Thanks I was hoping it would not take creating a new tech, but in the text below, lets say for instance I wanted to make the cannon only available to 1 civ behind "DefaultUnit>UNIT_CANNON" I don't see any number 1 or 0 if I put DefaultUnit>UNIT_CANNON_0 would that do it or am I missing something?
Code:
<UnitClassInfo> <Type>UNITCLASS_GUNSHIP</Type> <Description>TXT_KEY_UNIT_GUNSHIP</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>-1</iMaxPlayerInstances> <DefaultUnit>UNIT_GUNSHIP</DefaultUnit> </UnitClassInfo> <UnitClassInfo> <Type>UNITCLASS_CATAPULT</Type> <Description>TXT_KEY_UNIT_CATAPULT</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>-1</iMaxPlayerInstances> <DefaultUnit>UNIT_CATAPULT</DefaultUnit> </UnitClassInfo> <UnitClassInfo> <Type>UNITCLASS_CANNON</Type> <Description>TXT_KEY_UNIT_CANNON</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>-1</iMaxPlayerInstances> <DefaultUnit>UNIT_CANNON</DefaultUnit> </UnitClassInfo> |
|
|
|
|
|
#5 |
|
Deity
![]() Join Date: Apr 2006
Location: New York State
Posts: 4,859
|
Just put "NONE" without the quotes. Then for the civ(s) you want to have the cannon:
Code:
<Unit> <UnitClassType>UNITCLASS_CANNON</UnitClassType> <UnitType>UNIT_CANNON</UnitType> </Unit>
__________________
Mods: Convert Production to Espionage, FinalFronterFlat, The Road to War Ultimate Edition for BtS 3.19, Star Trek |
|
|
|
|
|
#6 |
|
Chieftain
Join Date: Jun 2008
Posts: 11
|
Thanks I'll give it a go
I tried that and got this error and this is the section of the XML file. Code:
<UnitClassInfo> <Type>UNITCLASS_SCOUT</Type> <Description>TXT_KEY_UNIT_SCOUT</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>-1</iMaxPlayerInstances> <DefaultUnit>UNIT_SCOUT</DefaultUnit> </UnitClassInfo> <UnitClassInfo> <Type>UNITCLASS_EXPLORER</Type> <Description>TXT_KEY_UNIT_EXPLORER</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>-1</iMaxPlayerInstances> <DefaultUnit>UNIT_EXPLORER_NONE</DefaultUnit> </UnitClassInfo> <UnitClassInfo> <Type>UNITCLASS_SPY</Type> <Description>TXT_KEY_UNIT_SPY</Description> <iMaxGlobalInstances>-1</iMaxGlobalInstances> <iMaxTeamInstances>-1</iMaxTeamInstances> <iMaxPlayerInstances>4</iMaxPlayerInstances> <DefaultUnit>UNIT_SPY</DefaultUnit> Last edited by AlleyGator; Jun 26, 2008 at 08:29 AM. Reason: So not to double post |
|
|
|
|
|
#7 | |
|
Prince
Join Date: Feb 2006
Posts: 451
|
Quote:
|
|
|
|
|
|
|
#8 |
|
Deity
![]() Join Date: Apr 2006
Location: New York State
Posts: 4,859
|
Yes, <DefaultUnit>NONE</DefaultUnit> is what is needed. Also, what expansion pack is this for? BtS doesn't need modifications to Civ4FormationInfos, but Warlords and Vanilla may.
__________________
Mods: Convert Production to Espionage, FinalFronterFlat, The Road to War Ultimate Edition for BtS 3.19, Star Trek |
|
|
|
|
|
#9 | |
|
Chieftain
Join Date: Jun 2008
Posts: 11
|
Quote:
@deanej This isn't for any expansion I just have the CIV4 original game |
|
|
|
|
|
|
#10 |
|
Deity
![]() Join Date: Apr 2006
Location: New York State
Posts: 4,859
|
Since you have vanilla, if you remove any units you will have to find every instance of that unit in Civ4FormationInfos and remove it from there. Unfortunately, the vanilla Civ4FormationInfos file is a huge mess, with everything jumbled together without any formatting to make it easier to read (no new lines for different elements, no tabs, etc.). There are cleaned up versions that are far easier to read on this site. If you add units they will also have to be added to Civ4FormationInfos.
__________________
Mods: Convert Production to Espionage, FinalFronterFlat, The Road to War Ultimate Edition for BtS 3.19, Star Trek |
|
|
|
|
|
#11 |
|
Chieftain
Join Date: Jun 2008
Posts: 11
|
@Dryhad Using <DefaultUnit>NONE</DefaultUnit> did work the way I wanted it to,THANKS
@deanej Thanks for the info I will keep it in mind but right now I am not wanting to completely remove any units, just restrict which civs have use of them. AG |
|
|
|
![]() |
| Bookmarks |
|
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Which order should I modify XML files (XML Hierarchy) | ww2commander | Civ4 - Creation & Customization | 19 | Apr 04, 2007 05:13 AM |
| How much interest in a program to modify CIV4TechInfos.xml automatically? | Darva | Civ4 - Creation & Customization | 7 | Apr 20, 2006 05:17 PM |
| Edit XML file or Create alternate file | TripleGemini | Civ4 - Creation & Customization | 3 | Jan 23, 2006 03:57 PM |
| Modify the Origional file? Please no .... | weakciv | Civ4 - Creation & Customization | 19 | Nov 04, 2005 11:15 AM |
| Looking for Application to Modify a .sav file | I_batman | Civ3 - General Discussions | 4 | Aug 27, 2005 12:21 PM |