| 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 |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
HOW TO: Create a Civilization
The following is a guide to creating an entire Civilization (also known as an empire) in Civilization IV. This walkthrough will cover XML basics along with the XML files requiring modification, how to handle the art files, leaderheads, flags, buttons, along with some tips to get desired effects.
This tutorial is designed with the inexperienced modder in mind. There will be many sections dedicated to nearly step-by-step processes included in this rather large tutorial. Such as creating the leaderhead, designing U.U.s, setting up the A.I. of a leader, creating custom diplomacy text, and more. PLAN AHEAD! Before you begin, it is always a good idea to lay out a design before rushing into creating your own Civilziation. Some things you should consider:
SECTION 1 The Art Files When modifying the art files in Civilization IV, you're going to need a proper program to modify, DirectDraw Surface, or .dds files. .DDS files are basically similar to regular bitmaps, except that they contain the same image at different resolutions from large to small. Firstly, you're going to need a proper program to edit these .dds files. Personally I prefer DXTbmp, which properly generates the mipmaps (the same image at multiple resultions) and is relatively user friendly. SECTION 1.1 Creating the Flag The very first task you'll need to do to create a flag for your Civilization is a source image to create the flag from. Once you have your source image -- you want to resize its proportions to 128x128. ![]() ![]() Here is my Carthaginian flag from my Carthage mod on the left. As you can see it looks pretty nice at 128x128, and it's nicely set in the middle so it doesn't wrap around the actual flag mesh. There is only one problem however. When the game actually loads the image is actually "squished" by about 25% in the width, as you can see the results with the image on the right. To remedy this, we stretch the original image's width by 125% to cancel out this effect. Which results in a properly scaled image within the game. ![]() ![]() Now, with a properly scaled image, we can actually load the image into DXTBmp and create the .dds file. To do this, simply load up DXTBmp. Then select File -> Open and open up your 128x128 bitmap. Now, double click the white area labeled "Alpha Channel." This should load your default paint/image editing program. Now use the paint bucket tool and fill the entire white area with black. This will make the game use your RGB values rather than the player's in-game color to define the flag. Now, click File -> Save as -> DDS Texture. Before you save the image, click on the "Save as type" bar, and make sure that the image type is DDS DXT3. Try to keep the name of the file simple (LikeThis.dds). For implementation of the flag, skip to Section 2.3.1 of this guide. SECTION 1.2 Creating the Leaderhead Firstly, it's best to have a source image. Here I have a painting of Abraham Lincoln -- although it's been shrunk down for internet use. ![]() Now, when creating a leaderhead, it is a good idea to use the ideal proportions of 512x512, and remembering our law of 125% width from our previous enounter. With this in mind, I stretch this image to the proper proportions. ![]() Now it may look rather ugly in that sense, but once put into the game, you can see the results in diplomacy look MUCH more pleasing to the eye! ![]() Now, you want to treat the leaderhead file exactly as you did before with the flags. To create the .dds file, get DXTBmp and start it. Then select File -> Open and open up your 512x512 bitmap. Warning: Don't set the alpha channel black, otherwise there'll be problems with your 2D leaderhead. Click File -> Save as -> DDS Texture. Before you save the image, click on the "Save as type" bar, and make sure that the image type is DDS DXT3. SECTION 1.3 Creating Buttons Before you start creating buttons. Typically you'll need three buttons. One for the leaderhead, one for your Civ flag, and one for your Unique Unit. Make your buttons with this in mind for your Civilization. Button sizes are typically 64x64 pixels. The best idea when creating a button is to firstly create the image for the 64x64 image file. Then, put the image into the Civ4 border. The reason behind the border is that they create an illusion of a button shadow when the alpha channels are applied. This is the border I use; feel free to use it in your mods. ![]() The only difference now is the alpha channel. Here is the actual alpha channel used globally for Civ4 buttons. Make sure to set this up before you save your DDS DXT3 files. ![]() SECTION 1.4 File Arrangements Now that you've created the Art files you need to create the actual mod directory and place the files in their proper directories. Firstly, go into your Program Files\Firaxis Games\Sid Meier's Civilization IV\Mods directory. Now, create a directory of your choosing therein. So it'll be something like Sid Meier's Civilization IV\Mods\YourCiv\. Alternatively you can put your mods in the Warlords/Beyond the Sword expansion directories depending on what game you'd like to play your Civilization in. Note: Do not go into _Civ4CustomMods directory or your My Games\Sid Meier's Civilization IV\Assets directory. Or else save files may not work properly with your modification. Although I will say that you can put game modifications in the My games\Sid Meier's Civilization IV\CustomAssets\ folder, which will produce immediate results when starting CivIV instead of needing to load a Mod to produce the desired results. I recommend only using CustomAssets if you're simply changing graphics of existing civilizations, and not if you're adding new civilizations/leaders. Anyway, inside the mod directory -- create the following folders and place the art files. YourCiv\Assets\Art\Interface\Buttons\Civilizations \(your civ's button here) YourCiv\Assets\Art\Interface\Buttons\Units\(your UU's button here) YourCiv\Assets\Art\Interface\TeamColor\(your flag here) YourCiv\Assets\Art\Interface\Leaderheads\(your leaderhead here) YourCiv\Assets\Art\Interface\Leaderheads\(your leaderhead's button here) Fortunately, you do not actually need to specify a .ini file, as you will see in most mod directories, within the directory. It will be created automatically when the modification is loaded. It need only be modified if you feel it nessicary after you load your mod the first time.
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche Last edited by Jecrell; Jul 27, 2007 at 03:19 AM. |
|
|
|
|
|
#2 |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
SECTION 2
The XML Files Now that you've created the art files required for your civilization, you can put them into practice by setting up the XML files. Then you can tell the game where your art files are and how they are set up. Also, you can set up our civilzation's name, leaders, and Unique Unit statistics in these files. Now, editing XML files is as simple as opening the files in Notepad (I prefer Notepad++) and understanding a few concepts. There are several types of tags and inputs I've noticed. Firstly is the open and closed tags.SECTION 2.1 Getting the Needed XML Files Creating XML files from scratch is far too much work for anyone out to add a new Civilization. So it is best to borrow the original Civilization IV XML files and place them into our mod directory. You're going to need the following files from your Sid Meier's Civilization IV directory. Assets\XML\Art\CIV4ArtDefines_Civilization.xml Assets\XML\Art\CIV4ArtDefines_Leaderhead.xml Assets\XML\Civilizations\CIV4LeaderHeadInfos.xml Assets\XML\Civilizations\CIV4CivilizationInfos.xml Assets\XML\Interface\CIV4ColorVals.xml Assets\XML\Interface\CIV4PlayerColorInfos.xml Assets\XML\Units\CIV4UnitInfos.xml Assets\XML\GameInfo\CIV4DiplomacyInfos.xml You want to place copies of these files into your Mod directory similarly as the file structure presented above. SECTION 2.2 Setting up the XML Text File The XML text file for you Civilization is a unique kind of XML file. It is the only XML file to my knowledge that can have any filename of your choosing. The other XML files usually have text reference keys. These keys find our custom text references file and pull text data from it. Here is an example XML Text reference file for a Civilization with 1 leader. Feel free to change it and customize it however you see fit. Also included are many comments to help you in your civ creation process. http://www.filegone.com/pwlq (Dead link! To be fixed) You want to place that file in the following directory inside your mod directory. Assets\XML\Text\ Feel free to rename the file to anything you like, and change all the references inside to fit your Civilization and its leader. SECTION 2.3 Setting up the XML Art Files Now we can get started defining the art files so our Civ's graphics can show up in-game. Now, if you don't have any actual graphics prepared you can technically copy references already presented within the art files. So you could use Catherine as a placeholder and you don't need to make new leader/civ references if you reference already made art files. However, if you have new art files you want to add to the game (and have been following the tutorial thus far), you're going to need to append new references to the XML Art reference files. So, unlike our text file, we *need* the original files in their entirety. SECTION 2.3.1 CIV4ArtDefines_Civilization.xml Remember earlier how I explained the opened and closed tags? In this file, the opening tag and closing tag are seperated by a bunch of minature tags. So, the file starts out with... <CivilizationArtInfos> and ends with </CivilizationArtInfos> And puts <CivilizationArtInfo> </CivilizationArtInfo> (note no S on the end) tags in-between. So effectively, this file creates a list of the art infos for each Civilzation. We don't want to break this when we add our code in. In the effort of not breaking the file -- let's put the following lines of code after the last </CivilizationArtInfo>. Code:
<CivilizationArtInfo> <Type>ART_DEF_CIVILIZATION_YOURCIV</Type> <Button>,Art/Interface/Buttons/Civilizations/(your civ's button).dds</Button> <Path>Art/Interface/TeamColor/(your flag).dds</Path> <bWhiteFlag>1</bWhiteFlag> </CivilizationArtInfo> SECTION 2.3.2 CIV4ArtDefines_Leaderhead.xml If you understood fitting in your XML into the last file, you should have no problem with this one. There's some uinqueness here since the files like using 3D references -- which we can not yet use. New animated leaderheads are not yet supported, so we're going to make closed tags out of the 3D references. Here's the bit of code we need to add. Code:
<LeaderheadArtInfo> <Type>ART_DEF_LEADER_YOURLEADER</Type> <Button>,Art/interface/LeaderHeads/(your leader's button).dds</Button> <NIF>art/interface/LeaderHeads/(your leaderhead).dds</NIF> <KFM/> <NoShaderNIF/> <BackgroundKFM/> </LeaderheadArtInfo>
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche Last edited by Jecrell; Jul 26, 2007 at 02:18 PM. |
|
|
|
|
|
#3 |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
Reserved --
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche |
|
|
|
|
|
#4 |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
I'll be adding/revising a lot of this in the coming days. So any questions, comments, suggestions are welcome.
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche |
|
|
|
|
|
#5 |
|
Warlord
Join Date: May 2003
Posts: 224
|
Cool, I'll be following this. I have a couple questions. Does the civ flag have to be only 2 colors or can it be anything from a single color to a photo? Also, I was wondering what's required to either edit an existing animated leaderhead or create my own animated leaderhead. How difficult is it? I have a kind of cheap idea to use the Sims 2 to create a leaderhead out of a sim and try to animate him a little bit if it's at all possible and within my ability.
|
|
|
|
|
|
#6 |
|
Breizh A Tao
Join Date: Sep 2005
Location: Paris, première ville bretonne
Posts: 1,305
|
i think you should speak about the alpha channel and the way to create a decalc flag... if people think they just need to take an image for the flag, they will be disappointed...
gonna follow this
__________________
L'Ankou Going to write the book "getting fit with Prozac": I don't lose weight, but I don't care!!! |
|
|
|
|
|
#7 | ||
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
Quote:
Currently we're stuck with "flat" leaderheads. Quote:
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche Last edited by Jecrell; Nov 29, 2005 at 01:09 PM. |
||
|
|
|
|
|
#8 |
|
Chieftain
Join Date: Dec 2005
Posts: 1
|
u talk nothing about where to put all the stuff need to explain it more theroly to us noobies i mean i made all the pics anf flags and butons but now what.....................
|
|
|
|
|
|
#9 | |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
Quote:
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche |
|
|
|
|
|
|
#10 |
|
Chieftain
Join Date: Dec 2005
Posts: 10
|
This is very helpful! Thanks for your hard work. I've got my first civilization coming along faster than I expected.
|
|
|
|
|
|
#11 |
|
Chieftain
Join Date: Nov 2005
Posts: 24
|
Nice. I used this to get a start on my new civ.
Are you going to include a custom music for your civ in this too? I finally got my custom diplo music working for my civ, but it took me way longer than it should have. |
|
|
|
|
|
#12 | |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
Quote:
The next sub-sections of this will be the individual XML files in detail. I hope you've enjoyed the comments and such inside the custom Text .xml file. And seriously guys, feel free to criticize what has been published so far.
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche |
|
|
|
|
|
|
#13 |
|
Young Padawan
Join Date: Apr 2005
Location: Mighty Brittania
Posts: 296
|
Help Please!
I am trying to create my own mod and cant for the life of me add civilizations. as a tester i am trying to add Canada as a civ (after following somebody else's tutorial) but it when i load the mod it just wont show up in the civ selection screen (i.e. i cant play as them!) I have added Mods/Canada/Assets/ in which i have the following: /XML/Civilizations/CIV4CivilizationInfos /XML/Civilizations/CIV4LeaderheadInfos /XML/Text/CIV4GameText_Civilopedia_CivLeaders /XML/Text/CIV4GameTextInfos_Cities /XML/Text/CIV4GameTextInfos_Objects They have the appropriate text in them for a Canada civ (see Cv 4 XML Tutorial Part 1, 2 and 3 for details...its in the tutorials and guides forum). But i cant get the changes to appear, similar to in the mod i am trying to create. However, i downloaded the Europa Europa mod and that works fine...what am i doing wrong? Is it something to do with the fact that wheni load the mod it says "Loading XML[uncached]" however when it loads the original game it says "Loading XML[cached]" ? If so how do i change this? If not, stil how do i get it to work? Help is much appreciated! Its kinda driving me thanks a lot, mrkingkong |
|
|
|
|
|
#14 |
|
Chieftain
Join Date: Dec 2005
Posts: 10
|
Have you tried clearing the cache? You could delete the CustomAssets folder to force CivIV to reload all the xml files from your mod.
|
|
|
|
|
|
#15 | |
|
Young Padawan
Join Date: Apr 2005
Location: Mighty Brittania
Posts: 296
|
Quote:
thanks mrkingkong |
|
|
|
|
|
|
#16 |
|
Chieftain
Join Date: Dec 2005
Posts: 10
|
Delete the CustomAssets folder. There should be a folder for CivIV in My Documents\My Games\. CustomAssets will be in that folder. There is also a shortcut from the main directory where you installed CivIV.
|
|
|
|
|
|
#17 | |
|
Ruled: Civ3 - Civ5
Join Date: Oct 2005
Location: California, USA
Posts: 709
|
Quote:
Also, I don't like it when people add text to the default text files (You have 3 XML text files) -- it takes more time and energy to combine mods and its generally not good. You have no idea how many times I have said that in my history on this forum... it's like I'm yelling it until my throat bleeds. You can just make your own XML text file and add everything your mod needs into it. Did you define the Civ's art assets? Looks like you didn't since you're missing the CIV4ArtDefines_Civilization.xml, and CIV4ArtDefines_Leaderhead.xml files. Or did you just reference the default leaders/civs' art? And I don't think the cache has anything to do with it. You loaded the mod "uncached." Also, deleting your custom assets doesn't really delete the cache. If you have the patch for Civ IV, just hold shift while the game loads (or ctrl -- either shift or ctrl). That clears the cache.
__________________
“The man who fights too long against dragons becomes a dragon himself” Friedrich Nietzsche Last edited by Jecrell; Dec 05, 2005 at 04:31 PM. |
|
|
|
|
|
|
#18 |
|
Governor For Life
Join Date: Apr 2003
Location: Golden State
Posts: 2,901
|
how do Imake a UU?
__________________
Dr. Dre ft. Cosby |The California Civ and Mod Project|New Leader Traits|Numenor Map| |MySpace|Join the 2006 CivFanatics Fanatasy EPL League|Facebook|
Last edited by SoCalian; Dec 05, 2005 at 10:32 PM. |
|
|
|
|
|
#19 |
|
Warlord
Join Date: May 2003
Posts: 224
|
What should I do if I only want to add a new leader to an existing civilization with his own traits? I made my own leaderhead and I think I'd like to use it to add a second leader to the Romans with my own traits but keep everything else default.
|
|
|
|
|
|
#20 | |
|
Young Padawan
Join Date: Apr 2005
Location: Mighty Brittania
Posts: 296
|
Quote:
Any ideas what my problem could be then? I had a very similar problem in Civ 3 in that sometimes a change i had made in the files (if i had added a unit, for example) worked and sometimes it didnt. it is highly frustrating, as im sure you can understand. If i sent you the files is there any chance you could look through them to try and see what i am doing wrong? If not no worries! If so, thanks for taking the time to help a noob out. thanks in advance mrkingkong EDIT: when you say about the text files(i.e. you dont like it when people use the default text files,etc) , do you mean you can just have the one file, literally just enter what you want into it. Rather than following the naming pattern of the other files. Or is that just stupid (its not what iv done with my mod by the way) |
|
|
|
|
![]() |
| Bookmarks |
|
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How do you create your own civilization? | rckljohnson | Civ4 - Creation & Customization | 2 | Mar 18, 2008 04:44 AM |
| Let's create the Civilization 5 formula | Legal_My_Deagle | Civ4 - General Discussions | 19 | Nov 06, 2007 09:36 PM |
| Is it possible create 10 Civilizations in Civilization II Multiplayer? | Marcelo Koehler | Civ2 - Scenario Creation | 3 | Sep 24, 2005 07:41 PM |
| How to: Create a Buildable Leader, Create a General | Zippo | Civ3 - Tutorials, Reference, & Guides | 11 | Apr 19, 2005 02:05 PM |
| Add Civilization and PTW will NOT run - without new Civilization and SAME map is fine | rsheuman | Civ3 - Creation & Customization | 6 | Feb 18, 2003 04:48 AM |