• Civilization 7 has been announced. For more info please check the forum here .
Resource icon

C3X: EXE Mod including Bug Fixes, Stack Bombard, and Much More Release 18B

During testing I observed that when you investigate an AI city and repeatedly press P and close the window, you will get different numbers every time. Is this the result of a RNG element being recalculated every time? A "useless" building in AI eyes that gets its entire rating via perfume (a resource producing building in this case) does not have such variance and sticks to the perfume-set score.
That's right. There's an element of randomness in what the AI chooses to build and it works by adding a random number of points to the AI's valuations of its options. IIRC, the random number is chosen between -5 and +5. Perfume is added at the very end of the valuation logic so it's not affected by the randomness or any other factors in the AI logic.
I have one thing to chime in on the earlier obsoleting of improvements discussion: What if an obsolete building would simply cease incurring maintenance costs?
This is surprisingly tricky because each city's total maintenance cost is cached inside the city object, instead of being recalculated every time it's needed like most things. So when an improvement is built, its maintenance cost is added to the total, and when it's lost, the cost is removed. Nothing special is done when it's obsoleted of course. The game must recalculate the cost from scratch sometimes because it's affected by wonders granting free improvements being gained, lost, or obsoleted. I found a method that does that, although I don't know exactly when it's run. Oddly, that method does not charge maintenance for obsolete buildings, so I don't know what's going on there, maybe a bug. Anyway, this sort of thing is doable but would have to be done carefully.
Would it be possible to have a "simple" exclusion list for buildings that prevent others from being constructed when they already exist?
This is surely possible, again the hardest part would be reading in the exclusion lists from the text file and organizing them.
Do you think it is possible to make the AI's behaviour a little more reasonable in terms of rushing and gold-management?
I haven't looked at the AI logic regarding rushing, but I don't expect it would be difficult to influence its decisions.
Flintlock, I am very sorry for wasting your time with such a stupid mistake I have done. :blush: I couldn´t find the CCM testfile among my many dozens of config files, where I set the two worded resources in quotation marks (and some more such two worded resources in it), but after having done a new test file with a special focus, that even all two worded resources are set in quotation marks, all was working well (as you posted).

May be it could a good idea to add to the examples in the c3x_config file an example with a two worded building producing a two worded resource, like:
"Hydro Plant": local no-tech-req "Electric Power".
No worries :). I'll make a note for myself about adding such an example, that's obviously easy to do and might help. What would help more, and is a lot more involved, would be to remove the requirement to use quotation marks at all. In that list of building generated resources the quotes are redundant since the end of the resource name can already be found by searching for the , or ] characters. Unfortunately they're not redundant everywhere. In the building prereqs for units list, I used spaces to separate the unit names so there the quotes are necessary for multiword names. I could change that to use commas or something to separate but that would break config files from earlier mod versions. I'm not sure that it's worth it.

Like Alekseyev_ suggested, it might help to think of quotation marks as standard and only leave them off in special circumstances. Fun fact, that was actually what I had in mind when I originally programmed the mod's INI reader. Originally all strings were going to require quotation marks but then I decided to add the option to read single words as strings without quotes. That's why you don't need quotes around things like the names of the config options, but you can optionally include them. For example, instead of retreat_rules = standard you can write "retreat_rules" = "standard" and it will work the same.
 
I know it is a long shot, but anybody know how to run via MacOS? I have the GOG version of the game installed and running great on M2 MacBook Air via PortingKit (WINE). I can run CIV Assist as it is .exe via the same PortkingKit App, but I can't figure out how to trick the MacOS to run the bat file. Thanks.
 
Flintlock, in the CCM 2 thread I made here a post about the concept of "Special Resources" that are now possible with your great mod. :)
 
Flintlock, had to pass this on to you and others on the change to AI to use bombardment and escort them.

I had a turn a couple of days ago where Japan shows up with a stack of arty, around 45. It was escorted by 64 infantry, yikes. They bombarded my MA army and killed it. Not happy for sure.
Then I realized they did me a favor. Now, the stack was out on grass and I killed the escorts and took the arty. The loss of the army was meaningless to me as I was stuck with a leader I could not use for some time. We were capped at 512 cities and I was on defense, while the AI sent lots of units to die on my two towns I captured for the purpose of luring them. This was 250x250
31 civs AWE.

I am still on the fence about the change, though I thought I had switch to it being helpful to the AI, when that stack killed my army. Now I see all it did was destroy Japan (largest AI and AI tech leader). Now they have few units and lost 4 towns on that turn and I can finally break out. I think.

So all in all I now conclude it is only better for the change and maybe an occasional positive impact for the AI. Though a std map and non war game, it may be helpful to the AI. Not tried that. I am going to stick with it as it does provide a surprise at times and that is not all bad.
 
Flintlock, in the CCM 2 thread I made here a post about the concept of "Special Resources" that are now possible with your great mod. :)
Very nice. I'm glad to see someone's putting resource generation to use, it was quite a bit of work to get that working.
Flintlock, had to pass this on to you and others on the change to AI to use bombardment and escort them.
My experience too is that the AI's artillery usage doesn't make it more difficult to play against, but it does make it more interesting which I'd consider a success. I've been trying to think of a way to make the AI use its artillery more effectively but unfortunately I can't think of any easy way. Also I'm considering reducing the number of artillery it constructs, so it can build more offensive units instead, but that might backfire since that would mean its artillery stacks would be smaller and so easier to destroy/capture. What the AI really needs is better positioning and better coordination among its units. I doubt that's possible without overhauling the unit AI, which would be a huge job.
 
Very nice. I'm glad to see someone's putting resource generation to use, it was quite a bit of work to get that working.
Here is some additional feedback for those special resources: They are appearing in the civilopedia entry of units without any problems. Below is a screenshot showing both special resources "Steel" and "Capital Ships" of that unit.

Yamato.jpg


The screenshot also shows, that your "obsoleted by" entry is working, too. When clicking per example on the special resource "Steel", the following screen opens (the screenshot shows an early version without additional text):

Special Resource Steel.jpg


In all the civilopedia entries of CCM your fix of the hyperlink-bug is working. :thumbsup: Therefore at present I think, that I can change the format of the CCM Civilopedia back to normal C3C standards. On the other side, the reported crash when clicking in the AOI scenario on the resource "Industry", is still existing, even with the R14 version. According to the Quintillus editor, the resource "Industry" appears 113 times on the map of that scenario. Astonishingly the resource "Colonialism", that is appearing 273 times on that map is not triggering a CTD. Not counted are the additional links by many units. I suppose that crash could have another reason than the hyperlink bug. At least the number of links to a resource must be very high. Unfortunately the current download of that scenario needs also some other fixes before it can be played without any problems.
 
Last edited:
May I suggest having a look at "Charm"? tom2050 wrote an extensive thread on this: "Major Discoveries on Charm... CHARM WORKS"

As the AI mostly uses its Artillery to attack Units in Cities, Charm can be used as "Siege Artillery," to be used to specifically attack Improvements - even beginning with Walls.
 
They destroyed walls in one of their attacks. They have attacked cities and open field units. Not very charming, if you ask me lol.
 
Since I didn't get a response about running on MacOS, not sure this will be of any use, but if anybody else in the future using a Mac to play Civ3 comes across this and does a search here is how I got Flintlock's C3X patch to Ron on MacOS Ventura.

  1. Install Civ3 GOG via PortingKit
  2. Move C3X folder inside Conquests folder created by PortingKit
  3. Install Homebrew via Terminal
  4. Install Wineskin Server
  5. Create new Wineskin and run bat file from the executable line
  6. Go to original Civ3 App created by Porting Kit and play Civ3 with Flintlock's patch
 
May I suggest having a look at "Charm"? tom2050 wrote an extensive thread on this: "Major Discoveries on Charm... CHARM WORKS"
As the AI mostly uses its Artillery to attack Units in Cities, Charm can be used as "Siege Artillery," to be used to specifically attack Improvements - even beginning with Walls.
Related to this, someone (Predator145 IIRC) requested that charm bombard be modified to do normal damage to units instead of applying charm status. The point of that would be to create a kind of artillery that works like artillery used to in PTW, where it had a 2/3 chance of attacking buildings or pop in a city instead of the garrisoning units. I realize that's not exactly what you asked for since it's only 2/3 chance, but the advantage to doing that is the AI would be able to get better use out of it. If there were an artillery type that could only damage buildings, the AI would fire it uselessly against units in the field and against cities with no buildings.

Also related, in the next mod version I'm going to fix precision strikes by artillery units. It already sort of works in the base game, only precision striking is hard coded for air units, so it works off of operational range instead of bombard range and plays the bombing animation instead of the bombarding animation. Both those issues will be fixed. Unfortunately I highly doubt the artillery AI is able to perform precision strikes so this will allow artillery to selectively attack buildings and pop, but only for the human player.
Since I didn't get a response about running on MacOS, not sure this will be of any use, but if anybody else in the future using a Mac to play Civ3 comes across this and does a search here is how I got Flintlock's C3X patch to Ron on MacOS Ventura.
Thanks for sharing. I'll link to this post from the mod's readme so hopefully it will be found by anyone else who needs it.
 
It would be amazing to have the PTW style Artillery attacks by the AI! At higher levels I am able to withstand the AI Artillery stacks by just stacking more units in a town with Barracks, as they all heal the next turn. But this would force me to go after the AI Artillery stack before my city is reduced to rubble. The AI is smart enough to put them on a Hill 2 tiles away as well.

Thanks Flintlock, looking forward to the next version!!!
 
Related to this, someone (Predator145 IIRC) requested that charm bombard be modified to do normal damage to units instead of applying charm status. The point of that would be to create a kind of artillery that works like artillery used to in PTW, where it had a 2/3 chance of attacking buildings or pop in a city instead of the garrisoning units. I realize that's not exactly what you asked for since it's only 2/3 chance, but the advantage to doing that is the AI would be able to get better use out of it. If there were an artillery type that could only damage buildings, the AI would fire it uselessly against units in the field and against cities with no buildings.
Charm does work a bit counterintuitively: "Destroying City Buildings - It seems Charm artillery pieces WILL NOT destroy a city building UNLESS a building with Charm Barrier is present in the city! Then it will destroy all other buildings 1st, and will destroy the Charm Barrier building last." Leaving Walls as the only Improvement without a Charm Barrier would enable Siege Towers to properly function in-game, and give true meaning/purpose to "true" mobile siege artillery pieces like the WW2 Morser -

morser06.jpg


Just sayin' :)
 
Related to this, someone (Predator145 IIRC) requested that charm bombard be modified to do normal damage to units instead of applying charm status. The point of that would be to create a kind of artillery that works like artillery used to in PTW, where it had a 2/3 chance of attacking buildings or pop in a city instead of the garrisoning units. I realize that's not exactly what you asked for since it's only 2/3 chance, but the advantage to doing that is the AI would be able to get better use out of it. If there were an artillery type that could only damage buildings, the AI would fire it uselessly against units in the field and against cities with no buildings.

Also related, in the next mod version I'm going to fix precision strikes by artillery units. It already sort of works in the base game, only precision striking is hard coded for air units, so it works off of operational range instead of bombard range and plays the bombing animation instead of the bombarding animation. Both those issues will be fixed. Unfortunately I highly doubt the artillery AI is able to perform precision strikes so this will allow artillery to selectively attack buildings and pop, but only for the human player.

Thanks for sharing. I'll link to this post from the mod's readme so hopefully it will be found by anyone else who needs it.
The AI will only use Precision Strike on units with the "Air Bombard" AI strategy flag. And for that they need operational range. Note that when doing this it doesn't matter if your unit is a land or air unit, it will count as air and thus it can be intercepted by fighters, anti air improvements and shot by by units with AD value.
 
From that link of charm discoveries are these two things that I don’t like. That and I can never get those cracked editors to work! I just want the old PTW Artillery back!!

4. Units cannot be targeted multiple times by charm bombard. Once they are hit and their defense lowered, they cannot be further affected.

8. All units in a stack may be affected by a single charm attack, which halves their defenses. Each unit of a stack will be checked against the Bombard Str/RoF of the attacking Charm unit, and all units in the stack which 'lose' will have their defense halved,
 
Top Bottom