Python (civ4 scripting language) tutorial thread

First: welcome at CFC.

Second: Man, you've directly chosen something, which has problems at more than one place.
a) The output-generation of plots is not controlled by python files, it's controlled by the CvGameCoreDll, which is generated out of the SDK files, which are written in C++.
b) Plots at all do not generate any commerce. If you want to let them do this, you'll have to make a major hack into the system.

hmm...
I see.
I was afraid of this.
Thank you very much anyway. =)


..but for the second option I thought?
I suppose that in Python it's possible to make a building giving bonus commerce (like culture) per each terrain type in city area (it's similar to what National Park wonder does: the only difference is that it does it per improvement type in city area and gives free specialists).
For a building is normal to produce commerce per something (like Holy Cities) and since there's a script that looks for terrain improvements in the city area for this purpose, I think it's likely possible.
Isn't it?
The only problem is that, as usual, I can't really find this script...

It's name should be ImprovementFreeSpecialists.
I tried to search it here, but since it's a database updated to Warlords and National Park is from BtS, there isn't any trace of it.

By the way:
I'd like to inform Gingerbread Man that the link on his site regarding classes and methods' documentation is broken.
 
Ok:
I've found a guy who has tried the same thing I'm looking for (a way to produce a certain commerce per feature)
http://forums.civfanatics.com/showthread.php?t=355325

The problem is that when I try to load BtS it gives me loading XML errors.
Is there someone (an angel) that could gently take a glance at the script Black Whole has written in the linked post and tell me if there's some error, please?
 
I'm not sure if Gingerbread Man is still looking at this post, but if he is I'd just like to say good job sir, and thank you! I've recently became interested in modding after spending countless hours playing other peoples creations and this was just what I was looking for to help start that process. I truly appreciate the time and effort you put into this tutorial to help people like me get started. Kudos, and thank you again!
 
Top Bottom