Quick Modding Questions Thread

2) don't do that with buildings where a civ has an UB for that type (e.g. barracks, because the Zulus have an UB), because there has to be a bug somewhere in the .dll, it doesn't work properly then.

Hmm never heard of that
Does it supply a crash or does it not recognize the fact that the UB was built so the units are still unbuildable?
 
The prereq building for units takes a building type, not a building class. Any civ that has a UB instead of that building type will therefore not be able to build the unit because it gets a building of a different type.

The XML-only workaround it so make any civ that has a UB for a building that is required by a unit type also have UUs for those units. These new UUs will require the UB instead of the regular building type. The units can be identical to the regular unit in every respect (if you don't want to give the civ more actual UUs) except for the building type needed to build them (and the actual unit type tag, of course), but will clog up the civilopedia with redundant entries.
 
3) I'm not sure this will work because I haven't tried it, but you might be able to give the tactical nuclear missiles their own SpecialUnit type instead of SPECIALUNIT_MISSILE, but that would mean that anything that carries SPECIALUNIT_MISSILE already wouldn't be able to take t. nuke missiles anymore. Essentially, you'd be dividing all missile carrying ships into "nuke" and "non-nuke".
[/url]

A work around that i thought about after reading this was to create a new special class of missiles.

So u have spcunit_missile, which is guided missiles and tactical nukes,
Then i have spcunit_missile2 which is a copy paste of a guided missile except for the special tag and the name tags changed?

Another question i had was of city production. Right now even if i have more production than i need for something, i can only make a max of one thing per turn per city.

Is there a way that if i have 4 units qued up that take 50production each and i have 200production in my city, all four units will be made in one turn?
 
A work around that i thought about after reading this was to create a new special class of missiles.

So u have spcunit_missile, which is guided missiles and tactical nukes,
Then i have spcunit_missile2 which is a copy paste of a guided missile except for the special tag and the name tags changed?

Might confuse the playe, but else I don't see a reason why it should not work.

Another question i had was of city production. Right now even if i have more production than i need for something, i can only make a max of one thing per turn per city.

Is there a way that if i have 4 units qued up that take 50production each and i have 200production in my city, all four units will be made in one turn?

Can be done, but needs SDK. For a mod component please see here.
 
1)Theres an error in my mod when your art level is not on high, units art is mesed up. When you click on the unit it looks fine but when you unlick it, the art changes to something random and completely different unit. Any idea why? On high art level there is no such error
2)I want to change UN to EU. Any idea where that text is? I looked in all the text files and can't find it :mad: (I changed building already but i want to change it so the atually diplovote is different). And anyone know where i can change diplovote info??is there an xml file for it?
 
1) activate animations in the graphics settings

2) I think the text has to be changed in the original text files/you have to copy the TXT_KEY_ tag over, because it's not dynamically linked ingame.
And: GameInfo\VoteInfo or GameInfo\VoteSourceInfo
 
1) activate animations in the graphics settings

2) I think the text has to be changed in the original text files/you have to copy the TXT_KEY_ tag over, because it's not dynamically linked ingame.
And: GameInfo\VoteInfo or GameInfo\VoteSourceInfo

Cant beleive i didnt look in votsource:blush:

And I could find it in original text files which is weird
 
Ok, back again. I'm trying to implement the modcomp that The_J linked me to, so for that I need to mess around with SDK. I went to this: http://modiki.civfanatics.com/index.php/How_to_Install_the_SDK at the modiki, but am stuck at the Setting up the Project. I'm using Visual Studio 10 and I can't find the Makefile template anywhere. Someone got any ideas?

EDIT: Nevermind, I realized I didn't install C++ when I was installing Visual Studio, I only installed VB to save time. I was too lazy to hunt down my disc and just downloaded C++ Express and Makefile project is there.
 
Me again!!

I have just finished compiling (I HOPE!!) my dll, but I am now getting an xml error on the unitinfoclass on my great protector specialist. all the entries should be right as I haven't changed them, can anyone think of a reason why this might suddenly happen. The addtioin to the .dll was kmod, good this be something to do with the BUG interface, or perhaps events? I am trying to think what other things kmod brought with it, but I can't think of others.

So what files might reference a great person, and make this new great person invalid??

or any other thought on why suddenly it may have become invalid...
 
failed loading XML file xml\Units/CIV4UnitClassINfos.xml.
LoadXML call failed for Units/CIV4UnitClassInfos.xml.
Tag: UNITCLASS_GREAT_PROTECTOR in Info class was incorrect
Current XML file is: xml\GameInfo/CIV4SpecialistInfos.xml
Tag: UNITCLASS_SCIENTIST in info class was incorrect
Current XML file is: xml\GameInfo/CIV4SpecialistInfos.xml

Then it goes through each of the specialist types, I am assuming that these are jsut from the broken file.


LoadXML call failed for Units/CIV4UnitClassInfos.xml.
Failed Loading XML file xml\Units/CIV4AnimationInfos.xml
Failed Loading XML file xml\Units/CIV4AnimationPathInfos.xml
LoadXML call failed for Units/CIV4AnimationPathInfos.xml.
Failed Loading XML file xml\Units/CIV4PromotionInfos.xml
LoadXML call failed for Units/CIV4PromotionInfos.xml.

Allocating zero or less memory in
CvXMLLoadUtility::SetVariableListTagPair
Current XML file is: xml\Civilizations/CIV4TraitInfos.xml
There are more siblings than memory allocated for them in
CvXMLLoadUtility::SetVariableListTagPair
Current XML file is: xml\Civilizations/CIV4TraitInfos.xml

then onto promotions and some other files, if you want the exhaustive list I can continue later.

Cheers guys
 
hmm been through the trait file, and none of the tags look broken...

it worked before i did the dll, but I don't know anymore because a lot of the changes are sdk, python and xml, so without the .dll other things break....

I hate it when it goes wrong but the error doesn't tell me anything I can use...

what is really confusing me is that the trait info appears to be displaying properly, at least in the civilopedia, but it is the units and promotions that have vanished from the civilopedia....
 
A sonar promotion? That's an interesting idea, but I don't think it can be done...not in the base XML, that is. I'm helpless when it comes to doing anything with the code itself (or with Python, for that matter :blush:).
 
Yesterday was the first time I did any CivIV modding in 4 years. My former computers ran Windows XP. My current one uses Windows 7. All modding I have done is in Python. 2 Questions:

1) Previously for debugging, I would follow the advice given by The Great Apple in his Python Tutorial in the Modding Tutorials and References subforum. Specifically post 5. I would make the recommended edits to the CivilizationIV.ini file (except for ShowPythonDebugMsgs which never appeared in my ini file) and then launch CivIV and start a game using the modded python file.

Yesterday the recommended changes to the .ini file were automatically reversed whenever I launched CivIV.

I enter the ini file. I change these lines:

HidePythonExceptions = 1
LoggingEnabled = 0
OverwriteLogs = 0
SynchLog = 0
RandLog = 0
MessageLog = 0

to these lines

HidePythonExceptions = 0
ShowPythonDebugMsgs = 1
LoggingEnabled = 1
OverwriteLogs = 1
SynchLog = 1
RandLog = 1
MessageLog = 1

I save and exit the .ini file. I then reenter the .ini file to see that the changes have been saved:

HidePythonExceptions = 0
ShowPythonDebugMsgs = 1
LoggingEnabled = 1
OverwriteLogs = 1
SynchLog = 1
RandLog = 1
MessageLog = 1

I exited the .ini file again. I launch CivIV. I then reenter the .ini file to find that the changes I made have been reversed.

HidePythonExceptions = 1
LoggingEnabled = 0
OverwriteLogs = 0
SynchLog = 0
RandLog = 0
MessageLog = 0

Edit: I'm running BetterAI (which never gave me a problem before) and BUG mod which might be responsible for this. I'll try it with BUG mod disabled later.

2) A problem with Windows 7. When editing a map script in

C:/Programs (x86)/Firaxis/Sid Meier's Civilization IV/Public Maps

my computer won't let me save the newly edited version to the same location. The following error message is generated:

[Error 13] Permission denied: "C:/Program Files (x86)/Firaxis Games/Sid Meier's Civilization 4/Public Maps/LandMassesRevisited.py"

but I am able to save the file to another location and then copy it over to that location. Any hints on how to get around this error?
 
Back
Top Bottom