Adding a new building

ok I dont mess with CIV4CityLSystem.xml file specifically for that reason...

if you dont get it right... (exactly) it is finicky and crash on you...:(


I dont edit it so the buildings I use appear in the creation city screen and the civilopedia but not in the actual game map... it doesnt affect gameplay... just allows a model for when you zoom in on your city

it really doesnt matter... but I guess if you wanted to be thorough you'd edit that file...

however I had bad experiences with it and heard alot of bad stories editing that file, that's why I dont bother with it....:eek:

there is a thread that talks about it... but I dont think it's 100%.... so try to look for it if you want to know...

or post in the general Creation and Customization forum and see if someone else can help you...

sorry but I cant help you there :sad:

that's one of the things (besides python and sdk coding) I cant comprehend! :(
 
Reene, Did u say that you were able to get your buildings in the game to be built and also show up in your city when you zoom in, or only to show up under the buildings built in your city and in the civilopedia?
 
Reene, Did u say that you were able to get your buildings in the game to be built and also show up in your city when you zoom in, or only to show up under the buildings built in your city and in the civilopedia?

I can only get them to show in the civilopedia and in the city screen

I can not get them to show up in the main screen when you zoom in on a city

however the reason they dont appear (main screen zoom city) because I dont edit the CIV4CityLSystem.xml file (which is the file you need to edit to get them to appear on your main screen city)

other people have done it but I have not since it crashes (see previous post)
 
Oh ok, that's what I thought, I was just making sure though. It's actually not the hardest file to edit, copying and pasting tends to work quite well, but when it doesn't, well that's when you encounter major problems
 
Oh ok, that's what I thought, I was just making sure though. It's actually not the hardest file to edit, copying and pasting tends to work quite well, but when it doesn't, well that's when you encounter major problems

it is a bit finicky
well then:

It's actually not the hardest file to edit, copying and pasting tends to work quite well, but when it doesn't, well that's when you encounter major problems


isnt that what I said?:p

that's why I dont bother with it..... to me it's not worth the trouble of trial and error (er trial and crashing :mad: ) since it doesnt affect gameplay :goodjob:
 
hi, i'm trying to insert WTC into my mod
( this one - http://forums.civfanatics.com/showthread.php?t=189865 )

may be you can find the problem i have? plz, take a look at this -
i'm attaching my file so u can see that everything is done like u said but still game crashes when building should be appeared in the city and u can't find it's graphic in civpedia. make fast search in files by ctrl f - wtc
thank you
 

Attachments

Hi!

I just found a bug:

you have written "ART_DEF_WTC" in the CIV4ArtDefines_Building, but "ART_DEF_BUILDING_WTC" in the CIV4BuildingInfos. It has to be the same in both files.
 
i can make wonders with this tutorial 2?
:crazyeye:
 
I've tried to follow this guide to making a new palace for a new civilization in the FFHII mod, but it doesn't show up in the city and I don't know why.

I know that:

* The mechanics of the building work, it shows up in the city list of buildings both on the side and as a button to build a new one.
* the art of the building works, when I replace an existing building's nif file with this building's nif file it shows up in game as the new art.

however the building just doesn't show up in my city, no matter what era its in. I tested to see if other buildings will show up, and none of the other palaces from any other race in FFHII show up either.

I tested to see if my new palace would show up as itself in another civilization's city, but it didn't :(.

I think that the only difference between this civilization and other civilizations is that i made a new ArtStyle for my civilization. Originally in FFHII there were ARTSTYLE_EUROPEAN, _ASIAN, _SOUTH_AMERICA, _MIDDLE EAST, GRECO_ROMAN, and _BARBARIAN. I included a new one, _SAEVALFAR. However the palace entries don't ever reference a particular artstyle or era they are just always shown. So I didn't think I had to mention it.
 
Kael has some unique palaces in FfHII already. Can you see what he did to make them work? I don't know, however, if they have been converted to the BtS beta version though.
 
With regard to the 'pinking' of buildings; this happened to me, and I've been spending hours trying to get round it. Whether my particular solution is relevant to anyone elses' problem, I don't know, but here goes:

I was basicly cut/pasting the graphic files for the FfH Infirmary into Next War, to use the building as a Kelp Processor (it's the only graphic file I could easily access that I could convince myself MIGHT look a bit like a factory?). So I changed all the XML easy enough; Chamaedrys' walkthrough at the start of this topic has all the details (if you have BtS, I don't think you even have to edit the Civ4CityLSystem to get your building to show up in-game; my Kelp Processor does and I havn't touched it).

The problem was that, while I had the 3D model in fine, it was pink. It just refused to associate the texture with the model!

Long story short, the solution was: you can't rename the .dds or .nif files. I changed them from Infirmary.dds and Infirmary.nif to Kelp_Processor.nif & .dds, and, for some reason, the game didn't like that. Change them back to their original names, and it works like a charm. You can call the folder they're in whatever you want; just don't fiddle with the graphics' names themselves.
 
I am trying to add the "Gateway Arch" and here's what I've done so far. I have both Warlords and Beyond the Sword. The problem is that although the item shows up in the Pedia, there is no image/art and the button is wrong. I haven't tried to put it into a city yet. What have I done wrong?

I have made the following edits so far:

In:
Beyond the Sword\Assets\XML\Art\CIV4ArtDefines_Building.xml


I added the following node:
<BuildingArtInfo>
<Type>ART_DEF_BUILDING_GATEWAY_ARCH</Type>
<LSystem>LSYSTEM_3x3</LSystem>
<bAnimated>0</bAnimated>
<fScale>0.77</fScale>
<fInterfaceScale>0.65</fInterfaceScale>
<NIF>Art/Structures/Buildings/Gateway_Arch/The_Gateway_Arch.nif</NIF>
<KFM/>
<Button>,Art/Interface/Buttons/Buildings/GatewayArch.dds,Art/Interface/Buttons/Beyond_the_Sword_Atlas.dds,5,7</Button>
</BuildingArtInfo>

In the folder:
Beyond the Sword\Assets\Art\Structures\Buildings\Gateway_Arch

I have added these files, downloaded off this site:
The_Gateway_Arch.nif
steel_glossmap.dds
steel.dds

In the folder:
Beyond the Sword\Assets\Art\Interface\Buttons

I have added this file, downloaded off this site:
GatewayArch.dds

In the file:
Beyond the Sword\Assets\XML\Buildings\CIV4BuildingClassInfos.xml

I added this node:
<BuildingClassInfo>
<Type>BUILDINGCLASS_GATEWAY_ARCH</Type>
<Description>TXT_KEY_BUILDING_GATEWAY_ARCH</Description>
<iMaxGlobalInstances>1</iMaxGlobalInstances>
<iMaxTeamInstances>-1</iMaxTeamInstances>
<iMaxPlayerInstances>-1</iMaxPlayerInstances>
<iExtraPlayerInstances>0</iExtraPlayerInstances>
<bNoLimit>0</bNoLimit>
<bMonument>0</bMonument>
<DefaultBuilding>BUILDING_GATEWAY_ARCH</DefaultBuilding>
<VictoryThresholds/>
</BuildingClassInfo>

And in the file:
Beyond the Sword\Assets\XML\Buildings\CIV4BuildingInfos.xml

I added this node, redacted to relevant values:
<BuildingInfo>
<BuildingClass>BUILDINGCLASS_GATEWAY_ARCH</BuildingClass>
<Type>BUILDING_GATEWAY_ARCH</Type>
<SpecialBuildingType>NONE</SpecialBuildingType>
<Description>TXT_KEY_BUILDING_GATEWAY_ARCH</Description>
<Civilopedia>TXT_KEY_BUILDING_GATEWAY_ARCH_PEDIA</Civilopedia>
<Strategy>TXT_KEY_BUILDING_GATEWAY_ARCH_STRATEGY</Strategy>
<Advisor>ADVISOR_GROWTH</Advisor>
<ArtDefineTag>ART_DEF_BUILDING_GATEWAY_ARCH</ArtDefineTag>
<MovieDefineTag>ART_DEF_MOVIE_GATEWAY_ARCH</MovieDefineTag>
...

(I have the movie installed too but that's the least of my worries).

Thanks!
 
Hi,

I'm new at this, so my mistake is probably a simple one. I followed the instructions here to add a new building. I tried with a barracks and a Christian Temple.

When I run the mod the new building appears in the list of buildings to choose, but it appears as two of the original building that mine is based on. Two barracks buildings appear on the list. Both buildings have the same stats as the original. When one is built the other disappears from the list.

In worldbuilder the buildings both appear as they should, the new one with its new name and stats. If I put them in a city using worldbuilder they perform normally with their new stats. Why can't I build the new building normally?

Thanks for any help.

JB
 
ok ive added a new national wonder, or at least its suppose to be, but instead of coming up as a national wonder its just a regular building that can be built in every city. any thoughts on what i missed? i cant find anything missing or extra that would do that.

never mind lol found out what i did wrong. i had the max instances at -1 instead of 1

but i have a new problem. one of the new buildings i added, an archery range, causes a CTD when you try to build it. none of the other buildings ive put in have this issue so i dont know why this one does.
 
I am trying to add the "Gateway Arch" and here's what I've done so far. I have both Warlords and Beyond the Sword. The problem is that although the item shows up in the Pedia, there is no image/art and the button is wrong. I haven't tried to put it into a city yet. What have I done wrong?

I have made the following edits so far:

In:
Beyond the Sword\Assets\XML\Art\CIV4ArtDefines_Building.xml


I added the following node:
<BuildingArtInfo>
<Type>ART_DEF_BUILDING_GATEWAY_ARCH</Type>
<LSystem>LSYSTEM_3x3</LSystem>
<bAnimated>0</bAnimated>
<fScale>0.77</fScale>
<fInterfaceScale>0.65</fInterfaceScale>
<NIF>Art/Structures/Buildings/Gateway_Arch/The_Gateway_Arch.nif</NIF>
<KFM/>
<Button>,Art/Interface/Buttons/Buildings/GatewayArch.dds,Art/Interface/Buttons/Beyond_the_Sword_Atlas.dds,5,7</Button>
</BuildingArtInfo>

In the folder:
Beyond the Sword\Assets\Art\Structures\Buildings\Gateway_Arch

I have added these files, downloaded off this site:
The_Gateway_Arch.nif
steel_glossmap.dds
steel.dds

In the folder:
Beyond the Sword\Assets\Art\Interface\Buttons

I have added this file, downloaded off this site:
GatewayArch.dds

In the file:
Beyond the Sword\Assets\XML\Buildings\CIV4BuildingClassInfos.xml

I added this node:
<BuildingClassInfo>
<Type>BUILDINGCLASS_GATEWAY_ARCH</Type>
<Description>TXT_KEY_BUILDING_GATEWAY_ARCH</Description>
<iMaxGlobalInstances>1</iMaxGlobalInstances>
<iMaxTeamInstances>-1</iMaxTeamInstances>
<iMaxPlayerInstances>-1</iMaxPlayerInstances>
<iExtraPlayerInstances>0</iExtraPlayerInstances>
<bNoLimit>0</bNoLimit>
<bMonument>0</bMonument>
<DefaultBuilding>BUILDING_GATEWAY_ARCH</DefaultBuilding>
<VictoryThresholds/>
</BuildingClassInfo>

And in the file:
Beyond the Sword\Assets\XML\Buildings\CIV4BuildingInfos.xml

I added this node, redacted to relevant values:
<BuildingInfo>
<BuildingClass>BUILDINGCLASS_GATEWAY_ARCH</BuildingClass>
<Type>BUILDING_GATEWAY_ARCH</Type>
<SpecialBuildingType>NONE</SpecialBuildingType>
<Description>TXT_KEY_BUILDING_GATEWAY_ARCH</Description>
<Civilopedia>TXT_KEY_BUILDING_GATEWAY_ARCH_PEDIA</Civilopedia>
<Strategy>TXT_KEY_BUILDING_GATEWAY_ARCH_STRATEGY</Strategy>
<Advisor>ADVISOR_GROWTH</Advisor>
<ArtDefineTag>ART_DEF_BUILDING_GATEWAY_ARCH</ArtDefineTag>
<MovieDefineTag>ART_DEF_MOVIE_GATEWAY_ARCH</MovieDefineTag>
...

(I have the movie installed too but that's the least of my worries).

Thanks!


Ok, im by no means an expert but i think i might be able to help with one of those problems...

In Vanilla Civ 4, if you want the button to "work" then you have to remove the reference to the atlas file and the comma before the button file path (in Civ4ArtDefines_Building). So it would look like this:

<Button>Art/Interface/Buttons/Buildings/GatewayArch.dds</Button>

Its not perfect (as you may notice, the in-game pop-up bubble thing is pink) but in the pedia etc it works!

mrkingkong

PS>>> Just spotted, are you sure that you have referenced the button correctly, ie. have you referenced "art/interface/buttons/BUILDING/GatewayArch.dds" when it should be "art/interface/buttons/GatewayArch.dds" ??
 
i've read this whole forum and a lot of people have problems so sorry to add to the list but i added my unique building for a civ i made and everything works fine (pedia, button, graphics, text) and it comes up in the build options ... but when i click to build it my game crashes

i copied the nif file from a different building but that didn't work, then i did a blank nif tag and that diidn't work

the only thing i can think is CityLsystem.xml ... but i searched the whole think and i can't find the building specific tags .... i think i've attached my file to this (this is my first attatchment) and any help is appreciated
 

Attachments

@peteandbill:

The reason for it crashing at this point is a problem with the art files, usually in my experience the CityLSystem one. HOWEVER, I ONLY EDIT VANILLA CIV 4 FILES, AND UNFORTUNATELY THE ORGANISATION HAS CHANGED SINCE BEYOND THE SWORD ARRIVED- THIS ADVICE MAY NOT BE OF TOO MUCH HELP.

I had a lot of problems with my buildings that i created referencing 'leafs' that were of an incorrect size for the graphics, which causes the crash.

I would recommend PMing the person who created the art for the building and asking them which size 'leaf' they used, and it would be even better if they could give an example for you of what XML code you need to put into the file for it to work. Im sure if you ask nicely they will (unless they are really mean/busy lol).

Hope that helps, like i say, im by no means an expert.
 
Hi,

I'm new at this, so my mistake is probably a simple one. I followed the instructions here to add a new building. I tried with a barracks and a Christian Temple.

When I run the mod the new building appears in the list of buildings to choose, but it appears as two of the original building that mine is based on. Two barracks buildings appear on the list. Both buildings have the same stats as the original. When one is built the other disappears from the list.

In worldbuilder the buildings both appear as they should, the new one with its new name and stats. If I put them in a city using worldbuilder they perform normally with their new stats. Why can't I build the new building normally?

Thanks for any help.

JB

If in the XML file Civ4BuildingInfos both the files are pointing to <Type>BUILDING_BARRACKS</Type> (or something similar) then this could cause whacky things like this to happen in game. The text files can be the same, but if these 'Types' are the same then effectively the game sees two entries for the same building, causing problems. Hope that helps.
 
Back
Top Bottom