View Full Version : How do I add a new unit?


Modeltrainman
Aug 16, 2008, 11:06 AM
I read the tutorial, and understand XML somewhat, but I don't even know what files I'd need, it's a locomotive from Railroads!, I have that game too, so the files are mine. Please help, is what I'm trying to do even possible?

Arian
Aug 16, 2008, 11:21 AM
OK do this:

1. Add the art (nifs, dds etc) in assets\art\units

2. Add a button in assets\art\interface\buttons\units

3. Add text-tags in i.e. Civ4GameText.xml for:
TXT_KEY_UNIT_MYLOCO
TXT_KEY_UNIT_MYLOCO_STRATEGY
TXT_KEY_UNIT_MYLOCO_PEDIA

4. Add the art-tag in CIV4ArtDefines_Unit.xml i.e. ART_DEF_UNIT_MYLOCO
Point your art to the files in 1 and 2

5. Add the unit-tag in CIV4UnitClassInfos.xml i.e. UNITCLASS_MYLOCO

6. Add the unit-tag in CIV4UnitInfos.xml i.e. UNITCLASS_MYLOCO

Restart your mod and the unit should be there.

Modeltrainman
Aug 16, 2008, 12:32 PM
I did all that and it doesn't show up or throw out an error. What am(or could I) be doing wrong?

Arian
Aug 16, 2008, 12:47 PM
The Nif is missing/broken whatever??

In NifSkope your 4_4_0_american_dummies.nif isn't displaying anything??

Modeltrainman
Aug 16, 2008, 01:11 PM
Still no progress. I guess it can't be done. I thought it would be easy, because Civ4 and Railroads! share the same engine.(I imagine.)

Arian
Aug 16, 2008, 01:21 PM
I think there's something wrong with the model.

Modeltrainman
Aug 16, 2008, 01:23 PM
Thank you anyway, it is from Firaxis.

Arian
Aug 16, 2008, 01:29 PM
Isn't there a file called '4_4_0_american.nif' somewhere in a folder in Railroads? Since I don't have the game I can't check it.

Modeltrainman
Aug 16, 2008, 01:51 PM
The only .nif file there is 4_4_0_american_dummies.nif. I guess it can't be done.

Modeltrainman
Aug 16, 2008, 01:54 PM
I tried it with the Consoloidation, no luck there either. Do Railroads! and Civ4 even share the same engine?

Arian
Aug 16, 2008, 01:58 PM
I tried it with the Consoloidation, no luck there either. Do Railroads! and Civ4 even share the same engine?

I don't know but my guess is that the problem has something to do with the model.

grumbler
Aug 16, 2008, 06:09 PM
There's some discussion on adding models from Railroads! over here. (http://forums.civfanatics.com/showthread.php?t=265724&highlight=railroads)