Creating new XML tags

Slynky

Chieftain
Joined
Jul 8, 2006
Messages
3
I'm new to the Civ modding scene but i've got some XML experiance and a lot of time working on DOW and Warcraft 3.

For my first project I've been working on expanding the number of promotions. Unfortunatly there are no tags for some of the variables that I'd like to modify such as "chance to intercept" or "traverse impassable terrain"

Is it possible to add new tags to the Promotioninfos.xml and if so how do you go about doing it?
 
You'll also be wanting to add those tags to the DLL source code and programming how they're used (and importantly how the AI uses them).

Dale
 
Here is the step-by-step tutorial.

http://forums.civfanatics.com/showthread.php?t=166935

Note that it requires a little bit more knowledge to get working, since you have to use the SDK to actually make the code that will read the tag. However, more important is that you might need to use the SDK to change how the game works now that this new tag is available (although there is a good chance that you can do this from within some of the python functions such as those found within the CvGameUtils). The toughest part usually is getting the AI to correctly use and recognize the effects of newly added XML tags.
 
Most of that went over my head but thanks for pointing me in the right direction.
 
Okay, there's two parts to adding an XML tag:

1. Adding the tag to the XML file. This involves first adding it to the relevant schema file, then adding it to the XML file.

2. Telling the game what to do with the new tag. If required you may even need to write some code for the AI to use the tag. Because, any tag that adds functionality to a human that the AI can't use is very very very bad!

That's all really. :)

Dale
 
Back
Top Bottom