Quick Modding Questions Thread

Thanks a bunch, I will take a look at it.

A completely unrelated question: Can you save a given multiplayer game (PBEM to be exact) as Worldbuilder scenario like in singleplayer? It's utterly frustrating how the 800BC and 600AD starts are bugged in RFCMP so I thought maybe I could create an advanced start myself by playing until an arbitrary starting point and then save the current game as a scenario.
 
best answer is try it and see what happens :D

You talking about the civics or multiplayer->scenario?

I did add the file to my mod in the proper folder but it did absolutely nothing so there's still something I'm missing, but I can't figure out what. :scan:

Well don't I feel stupid now, I added the file to the wrong folder actually. :lol: The file works just fine and I can finally get on with actually creating content for the civics. :goodjob: Thanks again everybody who answered!
 
:confused: But how is that supposed to work? You can't open the Worldbuilder in Multiplayer!
 
Greetings--I'm trying to modify some small details of the game, here's my list:


TECHNOLOGY ATTRIBUTES:

* Change the Great Engineer from Fusion to Machinery


BUILDING AND WONDER ATTRIBUTES:


* Great Wall: enabled with construction, 250 :hammers: instead of 150, obsoletes with Rifling, latest start era being the Renaissance
* Forge and Mint: 2 citizens can become engineers
* Courthouse and all courthouse UBs: 2 citizens can become spies
* Laboratory and Research Institute: 2 citizens can become scientists
* Public Transportation: 2 base :health: instead of 1 base :health:, possibly adding 2 :) as well (to further add to the 2 :health: with Environmentalism).
* Walls/Dun, Castle: obsolete with artillery, not with rifling and economics, respectively.


SPECIALIST ATTRIBUTES:

* Engineer: 3 :hammers: instead of 2
* Great Engineer specialist: 6 :hammers: and 3 :science: instead of 3 and 3
* Priest: 1 :hammers: 1 :gold: 1:culture: instead of just 1 :hammers: and 1 :gold:
* Great Priest specialist: 2 :culture:, 4 :gold: and 2 :hammers: instead of 5 :gold: 2 :hammers:
* Great Artist specialist: 1 :science: 3 :gold: 12 :culture: instead of the latter two only.
* Possibly adding a military instructor (1 XP for military units) and modify the Great Military Instructor (3 XP instead of 2XP per unit)


-----------------------------------------

I do know that I have to change these XML files: CIV4TechInfos, CIV4SpecialistInfos, CIV4BuildingInfos; but I'm not sure if I have to change something else. What I do know is the game doesn't recognize the changes and claims there's a memory allocation error. If it helps I'm using Beyond The Sword 3.19 installed from CIV IV Complete. Any help will be greatly appreciated.
 
Hi everyone, I'm wondering about changing two things. Firstly I've changed the bomber range to be 25 however it's still showing as 8 in game, is there a max range cap of 8 on bombers and if so is there a way to change it?

Also I've made quite a few changes to the game now, added a lot of new units which I'm quite happy with. I start the game in the modern era, with technology capped. It's WW2 based, theres lots of tanks and things but every unit is limited in how many you can build apart from infantry, so the idea is the AI should have lots of fun units on defence and attack and as the game goes on it gets filled with basic infantry. However the AI seems to be doing quite badly and attacks and defends with hardly any units, often leaving only 5 units in a city even if I'm attacking it and it doesn't bother reinforcing it with other units it has in other nearby cities I'm not attacking. Often they just park up in my territory and dont attack, just pillage one tile then sit on it. So I'd like the AI to build more, attack and defend with much larger stacks and also attack my cities more when in my territory.

Ive tried unsuccessfully

I've changed the AI unit costs and build times to be really low in the handicap infos

In the leaderhead infos I've changed the "iBuildunitprob" to a much higher number in a couple of civs to experiment but it seems to do nothing.

changing their UnitAIweight modifier to UNITAI_ATTACK which also seemed to do nothing

Changed their "flavour" to "military"

They still just attack me with a pitiful force of say 5 units and fail in their attack (should I also change the <iAttackOddsChangeRand> to a lower number to stop this?)

and they also defend with a small force and the game is just too boring because it's too easy. I'd like them to attack and defend at least with stacks of 30+

So is there any way to get them to do this?

Im also not sure if the AI is confused that it's starting in the modern age with technologies blocked out or something
 
Also what software did you use to make the xml changes? Notepad++ is a good one,standard notepad is not such a good one.

Been using LibreOffice Writer (but use Notepad to tweak the file format into XML). Another thing I wonder is how do I put the modified files in order to make the tweaks usable. I know I've messed with the GlobalDefines and the terrain infos before, without any trouble.
 
@Dragon
start again and use notepad++ (it's free, and very useful, google it) to edit files, that will mean you don't have to do any tweaking, I am not entirely sure what you are doing when you 'tweak it' but my guess is you are introducing something incompatible.

Also, just incase you are, don't modify the original game files, copy them into a mod folder, using the same file structure, that way if you mess something up you don't break the game. So long as your folder structure is the smae as the bts structure terrain/terraininfos.xml (or whatever) it should be fine.



@reba

This may not be doable with xml changes (I am not sure though) likely it will require modifying the ai code in the dll to make them reconsider the 'power math' for working out if it needs more or less units. The other thing is does the ai have a strong enough economy to support so many units?
 
hi thanks, yeah I think they do have a strong enough economy because sometimes they're listed as wealthier than I am when I have a lot of gold. But I've just found the BTS Better AI mod, I've installed that and merged all my changes into it and hoping that could solve some problems because it looks like it could be a decent AI mod
 
I've just realised about the bomber issue too, though for whatever reason changing the iAirRange didn't work because there seems to be a max range limit, what I'll try to do instead is edit the nuclear missile to not suicide, have the bomber skin and only cause collateral damage on one tile etc. Hopefully that will work and the AI could use it properly if the UNITAI is kept the same as the bomber
 
@Dragon
start again and use notepad++ (it's free, and very useful, google it) to edit files, that will mean you don't have to do any tweaking, I am not entirely sure what you are doing when you 'tweak it' but my guess is you are introducing something incompatible.

Also, just incase you are, don't modify the original game files, copy them into a mod folder, using the same file structure, that way if you mess something up you don't break the game. So long as your folder structure is the smae as the bts structure terrain/terraininfos.xml (or whatever) it should be fine.


:goodjob: Thanks--already made all the regular changes (except for the wonders and the regular military instructor specialist) with success. As for the file placement, I placed modified copies of the corresponding files in the custom assets subfolders. Gonna try to merge those wonders, just need to get the appropriate graphic files.
 
So I've created a (melee) unit which is supposed to cause collateral damage. In the XML I gave it the following attributes:

<iCollateralDamage>25</iCollateralDamage>
<iCollateralDamageLimit>25</iCollateralDamageLimit>
<iCollateralDamageMaxUnits>3</iCollateralDamageMaxUnits>

However, when it attacks stacks of units, it never causes collateral damage. What is it that I have to change?
 
Does anyone know how CyCity's changeNoBonusCount(BonusType, iChange) works exactly? In particular, what values of iChange do what?
 
True or False.
Access to bonus, like what national park does to coal.
 
True or False.
Access to bonus, like what national park does to coal.

It's not true or false, but I figured it out: any positive number will block access to the specified resource, and to unblock it requires the corresponding negative value. Using an iCount of 0 has no effect at all. Uses of the function are cumulative too: if the total 'count' after multiple uses is positive the resource will be blocked, if it's 0 or less it won't be.
 
Anything above 0 == True == Block
0 == False == No Block

1, 2, 3 or 10000 means the same thing == True
 
Top Bottom