toft
Sep 18, 2007, 05:15 AM
Hey
I've made a new technology that when researched allows me to build a building. The pedia acts as it should, and I can place the building with WB and it looks fine. BUT! When I researched the tech, and upon starting to build the building... CTD!
I have no idea what I did wrong... anyone?
Fierabras
Sep 18, 2007, 02:18 PM
I might be an empty XML sub-structure. I have experienced CTD with that before. Example:
You have the following valid structure in Civ4BuildingInfos.xml:
<PrereqTech>TECH_GUILDS</PrereqTech>
<TechTypes>
<PrereqTech>TECH_CURRENCY</PrereqTech>
<PrereqTech>NONE</PrereqTech>
<PrereqTech>NONE</PrereqTech>
</TechTypes>
and now you change it to:
<PrereqTech>TECH_GUILDS</PrereqTech>
<TechTypes>
<PrereqTech>NONE</PrereqTech>
<PrereqTech>NONE</PrereqTech>
<PrereqTech>NONE</PrereqTech>
</TechTypes>
instead of:
<PrereqTech>TECH_GUILDS</PrereqTech>
<TechTypes/>
then you will probably get CTD on discovering the tech which enables the building. I think the same goes for techs and units.
toft
Sep 20, 2007, 05:46 PM
I might be an empty XML sub-structure. I have experienced CTD with that before. Example:
You have the following valid structure in Civ4BuildingInfos.xml:
<PrereqTech>TECH_GUILDS</PrereqTech>
<TechTypes>
<PrereqTech>TECH_CURRENCY</PrereqTech>
<PrereqTech>NONE</PrereqTech>
<PrereqTech>NONE</PrereqTech>
</TechTypes>
and now you change it to:
<PrereqTech>TECH_GUILDS</PrereqTech>
<TechTypes>
<PrereqTech>NONE</PrereqTech>
<PrereqTech>NONE</PrereqTech>
<PrereqTech>NONE</PrereqTech>
</TechTypes>
instead of:
<PrereqTech>TECH_GUILDS</PrereqTech>
<TechTypes/>
then you will probably get CTD on discovering the tech which enables the building. I think the same goes for techs and units.
I tried, but still I still get CTD. I have attached 2 images, if that might help.
Fierabras
Sep 20, 2007, 05:53 PM
I only guessed at what might be the problem. I might be able to help you, but then I need the buildings xml and the technologies xml file. You can PM me if you want to.
toft
Sep 20, 2007, 06:11 PM
I only guessed at what might be the problem. I might be able to help you, but then I need the buildings xml and the technologies xml file. You can PM me if you want to.
PM sent :D
Edgecrusher
Sep 21, 2007, 05:44 PM
I think it might be a problem with the Icon,
The technology is fine, The crash occurs when the game is trying to put the building in its "build list", i.e. the small round image of what the city is building.
I've had problems with that in the past.
Fierabras
Sep 21, 2007, 05:52 PM
You are right. The XML was fine, so I suggested to look at art files/definitions and Toft solved the problem himself.
I think most CTD's are due to problems with art. I actually recently found a way to crash through XML, so hence my earlier misconception