Adding buildings to Civ IV

Rob (R8XFT)

Ancient Briton
Retired Moderator
Joined
Aug 11, 2002
Messages
10,866
Location
Leeds (UK)
I'm finding it difficult to add new buildings to Civ IV and can't seem to find a tutorial either. I've tried looking at other mods where new buildings have been added, but don't seem to be able to get anything showing up in the game. Can anyone please point me in the right direction?
 
You need to change entries in the XML files inside the Assets\XML\Buildings directory. Then you will need to edit the art entries in the building-related file in Assets\XML\Art.

After that, it's just like adding units.
 
Saketh said:
You need to change entries in the XML files inside the Assets\XML\Buildings directory. Then you will need to edit the art entries in the building-related file in Assets\XML\Art.

After that, it's just like adding units.
I got that bit - but it still doesn't work. Could it be to do with the size of the building?
 
I think Rob might mean making so they don't overlap each other. If Vanilla has 10 ancient buildings, but you want to have 15 there could be some problems. Also if you have larger buildings you'll get overlap in the game.

If you did answer his question then I feel foolish for not answering that way from his PM. :blush:
 
Cross-post.

Whenever I take a screenie of a new building I try to switch it with a Vanilla of comparable size. I haven't delved into Civ4LSystem even though Kael has tried to help me.
 
Have you added the building to the CIV4CityLSystem.xml file? That is required for a new building to show up during a game and not just in the civilopedia.
 
Amra said:
Have you added the building to the CIV4CityLSystem.xml file? That is required for a new building to show up during a game and not just in the civilopedia.
Yes I have. If no-one's sure what I'm doing wrong, I'll simply have another go at it tomorrow. It's most likely to be a simple mistake I'm making.
 
Amra said:
Have you added the building to the CIV4CityLSystem.xml file? That is required for a new building to show up during a game and not just in the civilopedia.

That's not true at all. I've added zero new buildings to this file and they always show up in game. They aren't where I want them to be, but I have tons of screenshots to prove they are in game.

But since I may never understand the Civ4CityLSystem I'll agree that this is an issue. ;)
 
I still haven't quite cracked this, and it's rather annoying! I decided to try swapping the recycling plant (which won't be used in Anno Domini) for the Toolworker's house. Initially, I set it up as the recycling plant simply having a name change. Everything seemed to work out fine, so I put in woodelf's wheelwright to make the graphics more in line with what I needed. The wheelwright showed up in the civilopedia, and the button I created for it appeared in the selection window in my city. However, the moment I click on it to start building the Toolworker's house, the game is aborted! Has anyone any ideas how to help me?
 
That sounds like an ART_DEFINES issue Rob. The game will crash to desktop when there are issues with this.
 
Just to make sure we're on the same page:

In Civ4ArtDefines_Buildings XML file you found the Recycling Center and for now all you change is this line:

<NIF>Art/Structures/Buildings/wheelwright/wheelwrightB.nif</NIF>

where the wheelwright is the folder you created in the Art/Structures/Buildings folder and the wheelwrightB is the name of the nif I created.
 
woodelf said:
Just to make sure we're on the same page:

In Civ4ArtDefines_Buildings XML file you found the Recycling Center and for now all you change is this line:

<NIF>Art/Structures/Buildings/wheelwright/wheelwrightB.nif</NIF>

where the wheelwright is the folder you created in the Art/Structures/Buildings folder and the wheelwrightB is the name of the nif I created.
That's it. The other thing I did was created a button for the wheelwright, which shows up in-game.
 
Rob, try this mini-mod I just made. It only has that building and the XML file needed. I guess I don't understand what's going on since it works for me.
 

Attachments

Thanks for the help, woodelf; I've now cracked it. What I was doing in the ArtDefines_Building.XML was placing this line:

<Button>,Art/Interface/Buttons/Buildings/Toolmaker.dds</Button>

whereas I actually needed this:

<Button>,Art/Interface/Buttons/Buildings/Toolmaker.dds,Art/Interface/Buttons/Buildings_Atlas.dds,1,2</Button>


I can now put buildings into the game :goodjob: ; however I've experimented with your wheelwright as the toolmaker's house (increases production by 10%) - but despite working in terms of being built by the cities and showing up in the civilopedia, I don't actually seem to be seeing it within the cities once they build it. There seems to be a couple of buildings disappear to (presumably) make way for it, but nothing is actually built. Perhaps it's a sizing issue?
 
How big are you scaling it? In that mini-mod I sent it showed up, but I can't recall the scale.
 
woodelf said:
How big are you scaling it? In that mini-mod I sent it showed up, but I can't recall the scale.
I tried it at the scale you sent and it didn't show up in my mod. I take it the larger the number, the bigger the building?
 
Yeah, bigger is bigger. ;)

It does get hidden a lot I've noticed, but all buildings do eventually. I'm sure it's there, but not out in the open because of the default city buildings. You could swap it for the airport and watch it appear in the outskirts. Also, I'm trying to remove all of the buildings when you settle a city so every one you add is all that there is. I did it for some of my Sci-Fi screenies.
 
You'll be thankful that I've now cracked it and can add buildings with ease. I followed Amra's recommendation about adding the building to the CIV4CityLSystem.xml and it all works perfectly :) .

Thanks guys for all your help :goodjob: !!
 
I'm truly thankful and now I'll bug you when the time comes to explain that file!
 
Back
Top Bottom