Resource icon

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

I presume the key details have been carbon-copied in the dedicated thread, but this link is now depreciated so I'm starved for proper background in the ensuing discussions. :o

While we work to get districts out in R26 Preview 1, a quick question as I think ahead to maritime districts down the road: how should those be built?
As has been stated, it's a shame worker boats aren't AI-recognized or that would be the cleanest option. (Also the suggestion of deepwater bridges has my heart aflutter.)

Seconding Jorsalfare, the most reliable option would probably be auto-placement, with a logic to prioritize 'empty' coastal tiles closest to the city, and spiral out from there.

Even though I’ve been playing Civilization III for the past 15 years, using C3X has made the game more enjoyable than ever. So I wanted to write down a few additional ideas I’ve been thinking about.
...
1-1. Introducing Road Maintenance Cost
So we've discovered Civ 5. :mischief:

While I support the principle of more strategic logistic routes, one concern is that roads and railroads have tile-yield effects, so throttling them without a counterbalance could disrupt the economy. A 'local' road/RR level that improves yield without a movement bonus would solve this, but then we run into the issue of how many improvement layers before things get too tedious.

2. City Status and Defense Bonuses
I'm not sure about a starvation malus: for human players I can see the historical siege dynamic, but it feels like it'll be way too easy to outplay the AI by swarming all the tiles.

I like the principle of a refugee mechanic: the Civ2 scenario Red Front allows the player (Soviets) to evacuate frontline population via its settler units. Of course, without an appropriate AI strategy, the computer civs will just see the extra pops starve out if cities receive too many too fast.

5. Expanded Combat Bonuses
...
7. Improved Interaction Between Unit Classes
I'm glad you're enjoying my mod. I'll copy these ideas to my list of things to consider during and after implementing Lua scripting since they're mostly what I would consider post-Lua things. In fact some are things I would consider perfect examples of what I want to make possible using Lua, like the combat bonus for cavalry attacking onto flat terrain. Once there's a hook allowing Lua to modify combat odds and an interface letting it access units, unit types, tiles, and terrain, that would be very easy.
The combat system I propose keeps Civilization III’s fundamental structure — Stack of Doom combat — but changes the decisive factor of battles from sheer unit count to unit composition and order of engagement.
So we've discovered Civ4. :cool:

People were dunking on it earlier in the thread, and while it did take me literal years to figure out how the SoD actually functioned, I've come to understand its appeal—not better or worse than "classic" Civ combat, but different, and provides a good model for the schemes you've outlined.

Since more granular combat tweaks will likely be done via Lua, I will repeat my plug of the Civ2 ToTPP, and Dadais' mod that is a great demonstration of such custom rules in action.

7-2. Defensive Units Lose Fortify After Combat
...
8. Differentiation Between Archers and Artillery
I don't know about the first, but I fully support specialized 'de-fortifying' units, i.e. shock troops. I'm thinking specifically of flamethrowers in the trenches.

9. Production System Improvements
...
A paused project keeps its accumulated shields; switching to another project starts from zero.
Returning to the original project resumes it from the stored shield value.
I have no clue how hard this would be to implement within the game's current engine, but I would definitely love to see it.

11. Ethnic problems can also create unhappiness.
I would love if this is accompanied by a government trait that waives the penalty.

It also contains a set of optional rule changes to make land transports more viable
m-bison.gif


Not sure if these have been mentioned but the ability to adjust the SDI defense's percent change to intercept nukes.

The ability to reduce the collateral damage of nukes to a single tile or INCREASE IT and or turn off its unit collateral damage.

Then the ability to take the nukes collateral damage flag and apply it to other units giving them the ability to damage units in a stack would all be great features.
If this can be defined per-unit, we may finally have a pathway for 'tiered' nukes.
 
Last edited:
Question on City Limit change:

Does the new limit allow for new cities to be built in-game that exceed the old limit or does it just let you place more cities on a map with the editor without the scenario crashing on start up? Aka, let's say I have a Continental map with two major continents. On the Eastern Continent I have a thousand cities. Will this change allow for new cities to be built in-game on the Western Continent?

Also, is this new limit active by default upon installing C3X or do I have to activate it manually? If the latter, how do I do that?

Depending on your answers, I might just be able to resurrect my Colonization Redux scenario...
 
Is there a way to limit a unit's bombardment to sea or land tiles? I'm thinking of coastal artillery that can only target naval units and can't be turned inland, but it seems like this could have other applications as well.

And would there be any way to make it possible to modulate the radius of a nuclear explosion? Maybe using the Bombard Range value or something?
To bring this together with another request I made, is there a way to make tag certain terrain to block or be immune to bombardment? Like mountains would block most artillery bombardment (which presumably wouldn't be able to clear a mountain peak), and coastal guns wouldn't be able to fire onto land terrain.
 
Does the new limit allow for new cities to be built in-game that exceed the old limit or does it just let you place more cities on a map with the editor without the scenario crashing on start up? Aka, let's say I have a Continental map with two major continents. On the Eastern Continent I have a thousand cities. Will this change allow for new cities to be built in-game on the Western Continent?

Also, is this new limit active by default upon installing C3X or do I have to activate it manually? If the latter, how do I do that?
You can enable it anytime for ongoing game, and change it as many times as you want. Just load up the save and it will work right away allowing you to plant more cities.
It is a setting in default.c3x_config.ini that is in your conquest exe folder. Ctrl+F for city_limit = by default it is set to 512, you can put there any arbitrarily number you want up to 2048.
 
I presume the key details have been carbon-copied in the dedicated thread, but this link is now depreciated so I'm starved for proper background in the ensuing discussions.
That's correct, the dedicated thread is the place to go and has the most up-to-date information.

As has been stated, it's a shame worker boats aren't AI-recognized or that would be the cleanest option. (Also the suggestion of deepwater bridges has my heart aflutter.)

Seconding Jorsalfare, the most reliable option would probably be auto-placement, with a logic to prioritize 'empty' coastal tiles closest to the city, and spiral out from there.
I had initially been leaning towards this but have reconsidered, as there will likely be a number of maritime district types, likely including bridges and so on. The human player needs to have the freedom to determine where those are located.
 
I propose a new mechanic for a unit with a horse. It can retreat with a 50% chance, and the horse can also be killed with a 50% chance, and the unit itself can be saved. For example, if it is a regular rider, then if the unit is killed and it does not retreat, it has a chance to become a regular warrior and continue fighting.
 
While I support the principle of more strategic logistic routes, one concern is that roads and railroads have tile-yield effects, so throttling them without a counterbalance could disrupt the economy. A 'local' road/RR level that improves yield without a movement bonus would solve this, but then we run into the issue of how many improvement layers before things get too tedious.
There is a viable solution to the commerce imbalance caused by the reduction of road tiles.
By adjusting the terraform bonus values in the original Civ3 Editor, overall commerce can be rebalanced effectively.
Additionally, a trade road bonus system can be introduced.
When two civilizations engage in trade via the road network of a third civilization, the intermediary civilization gains an extra commerce bonus in the city through which the trade routes pass, based on the number of trade routes passing through that city. We can easily find such intermediary commerce bonus such as sasanian Empire, Kushan, parthia, ottomans, byzantine and so on.
I'm not sure about a starvation malus: for human players I can see the historical siege dynamic, but it feels like it'll be way too easy to outplay the AI by swarming all the tiles.
Oh, it does matter. I hadn’t considered the AI-related issues at that point.

but I fully support specialized 'de-fortifying' units, i.e. shock troops
:) ye... I wanna use various units in the war. in original civ3 we always attack with stack of doom which is full of one type of unit... for now I just added more assault infantry(medieval infantry-light infantry-flamethrower-anti tank- tow infantry)
I will repeat my plug of the Civ2 ToTPP, and Dadais' mod that is a great demonstration of such custom rules in action.
thx I'll try it :)
 
I propose a new mechanic for a unit with a horse. It can retreat with a 50% chance, and the horse can also be killed with a 50% chance, and the unit itself can be saved. For example, if it is a regular rider, then if the unit is killed and it does not retreat, it has a chance to become a regular warrior and continue fighting.
Cavalry already possess a significant advantage due to their high mobility and their ability to retreat.
Granting additional mechanics to cavalry would make them excessively strong.
Moreover, there are many other features that are more appealing, such as charge mechanics or skirmishing (radar) abilities and so on.
 
At least I think the 1 less call is due to that - I can see messages during the turn popping in when nations embargo you and then some cancel their embargo + some AIs embargo other AIs or something.
It's plausible and I don't have any better ideas. The game doesn't use many floating point operations. Even things like corruption and combat, which you'd think would have some float scaling factors, are all integers under the hood. Right off hand, the only places I recall seeing floating point ops in game logic are for worker strength and the science age bonus. Though having looked again in Ghidra, I see that there are a lot of float to int conversions in the AI logic as well, like to choose city production, order workers around, and evaluate research options. Civ 3 uses the x87 FP instructions, I wonder if those are better or worse than SSE for consistency between processors.

I tried to make my request as simple as possible. Can we get an option for a building to consume 1 population after being built?
Yes, deducting a point of population after certain types of buildings are completed would be very simple. The annoying part would be stopping buildings from completing if there's no pop for them and making the AI aware of the mechanic, if you want to bother with that.

Not sure if these have been mentioned but the ability to adjust the SDI defense's percent change to intercept nukes.
The ability to reduce the collateral damage of nukes to a single tile or INCREASE IT and or turn off its unit collateral damage.
Then the ability to take the nukes collateral damage flag and apply it to other units giving them the ability to damage units in a stack would all be great features.
It's fine if it's been mentioned already. I've gotten so many requests that at this point I usually don't recognize when they've been repeated anyway. Adjusting SDI interception chance ought to be easy, nuke damage not so much, there again it would be nice to call out to a Lua script to apply the damage.

To bring this together with another request I made, is there a way to make tag certain terrain to block or be immune to bombardment? Like mountains would block most artillery bombardment (which presumably wouldn't be able to clear a mountain peak), and coastal guns wouldn't be able to fire onto land terrain.
Easy enough for a bombard range of two, but for an arbitrary range you'd have to draw a line between the bombard unit's location and the target and check if any tiles along that line are of a type that blocks bombardment. The game does not have a function to do that, not that it would be particularly difficult to write one. Limiting certain unit types to bombarding only sea or land is something that's been requested before, I remember that one, and something I've had in the back of my mind for years now. It would be easy so I'll add it to the short list, for what that's worth as the short list is getting pretty long at this point like they always do.

You can enable it anytime for ongoing game, and change it as many times as you want. Just load up the save and it will work right away allowing you to plant more cities.
It is a setting in default.c3x_config.ini that is in your conquest exe folder. Ctrl+F for city_limit = by default it is set to 512, you can put there any arbitrarily number you want up to 2048.
Right except that the city limit defaults to 2048. I didn't see any reason to keep it lower.

I propose a new mechanic for a unit with a horse. It can retreat with a 50% chance, and the horse can also be killed with a 50% chance, and the unit itself can be saved. For example, if it is a regular rider, then if the unit is killed and it does not retreat, it has a chance to become a regular warrior and continue fighting.
That sure is an odd mechanic. What would a cavalry turn into? A musketman is a very different kind of unit and a rifleman is not necessarily available. And frankly if my horseman turned into a warrior, I think I'd just disband it.
 
Hi, the F1 screen shows turns left to complete. On maps with scores of towns, it is not easy to always tell if is 1 or 11 as the t in turn looks like a 1 at times.

Would be a big help, if it was Turn, rather than turn. Going to be 80 next month, so could use all the help I can get reading the list.
 
Love the mod, thank you, could not play without it.

A humble feature request:
- display culture flip chance percentage in city screen
- option to enable spying during war.
 
Civ 3 uses the x87 FP instructions, I wonder if those are better or worse than SSE for consistency between processors.
x87 nowadays is much worse in that regard. It's not even treated as second class citizen, and more like "it's a legacy abandoware by now, nobody will notice if the math results deviate a bit lmao" by Intel.
While I don't have any info on how it fares on AMD's side, for Intel there is only bad news, as between netburst->core2->first gen core i->newer generations there were undocumented changes by Intel that kept slightly reducing the accuracy of x87 FP ops - also occasionally some operations could corrupt the stored x87 register values, it was bad enough for M$ to completely prohibit usage of x87 (and MMX as well) registers on 64bit windows for kernel mode programs (so drivers, antiviruses, etc.), and recommend against/deprecate usage of it for user mode programs in their Visual Studio developer guidelines.
And that's without even counting in the common accidental register spilling issues in case of (long) double being used, something that historically old compilers from 90's to early 2000's were struggling with (and apparently for GCC even by 2008 it was/maybe still is an issue - x87note on their wiki), but that one wouldn't cause difference in results between people on different CPUs.
In general dealing with x87 can be really nasty. To this day people that write compilers for "newer" languages run into issues with it, as well as people that deal with multi arch emulators (like QEMU) and OS hypervisors (vbox).

What consequences would that have for Civ3 I don't know. For singleplayer probably none, so hopefully us C3X players should be safe. :) For multiplayer it could become an issue, where things silently break so hard that players end up playing a completely different game on their ends.
I've ran into that exact issue in some old RTS games when I was still on Intel platform and playing the game with friends where there was several generations gap in our CPUs, but would never desync with two friends that later I've learnt were only 1 CPU generation ahead and 1 behind me (i5 2400 I think, 3570k, 4770k). Back then at first I attributed it to buggy game code/maybe distance packet loss, but it could've been FP related.
If any weird problems crop up at least this info might give a clue as to where to look.
 
Yes, deducting a point of population after certain types of buildings are completed would be very simple. The annoying part would be stopping buildings from completing if there's no pop for them and making the AI aware of the mechanic, if you want to bother with that.

Ahh ok plan B then. Make a bldg consume 2 food per turn as a citizen does? If the city has a shortage of food then civ3 will act as normal and automatically take care of it the normal way by starving. The game will function as intended and no need to consider messing with any AI logic.
 
Hi, the F1 screen shows turns left to complete. On maps with scores of towns, it is not easy to always tell if is 1 or 11 as the t in turn looks like a 1 at times.
I'll look into it. This could probably be accomplished with a tiny change, problem is figuring out where to make it. Unlike the gameplay logic, I have never mapped out the code for the advisor screens.

Love the mod, thank you, could not play without it.
A humble feature request:
- display culture flip chance percentage in city screen
- option to enable spying during war.
My pleasure and I'm glad you like it. I agree it would make sense to show the flip risk on the city screen, problem is it's awkward to do since the formula to compute the risk is embedded in the method that flips cities. To extract it, I'd have to do something like call that method, intercept its call to the random number generator to determine what it's rolling up to, extract the min result to flip somehow, and make sure the city doesn't actually flip. It's possible, just awkward and more work than it ought to be.

For multiplayer it could become an issue, where things silently break so hard that players end up playing a completely different game on their ends.
I'd definitely expect this to be a big issue for multiplayer. As far as I know, from having heard about it but barely ever playing multiplayer myself, Civ 3 tends to be unstable and desyncs seemingly randomly. Though if the desyncs were caused by turn processing giving different results on different machines, it shouldn't be random. It shouldn't be the case that players can reload an old save and continue without a desync on the second try, which I believe is something they can do. So if this were an issue, it ought to be well known by the community at this point.

Ahh ok plan B then. Make a bldg consume 2 food per turn as a citizen does?
When you said the buildings were intended to stand in for specialists, I had assumed that you were planning to make them cost food all along. That's what I would have done. Two food per turn is a much bigger cost than one pop point, but you could balance around that. Problem might be that the AI shoots itself in the foot with those buildings since it won't know to build them in cities where food is abundant and avoid them in cities where food is precious. The AI doesn't account for generated resources at all when deciding what to build. You can apply perfume to the buildings to account for the value of the resource in general but that doesn't help for particular cities.
 
I have an unusual error in which at the end of the AI turn and as the game is cycling through the initial city builds (showing units built that turn and cultural expansion that turn), then the game just freezes. There are no special units, just the generic which had been built all game long. attached is the EXE mod settings I'm using -- did I set something up stupidly?


Seems to happen after all resistance ends in a city. The boxed city in the image if resistance ends, that's the last thing that happens before a crash. Likewise, if that city doesn't end its resistance, and if another city end its resistance then that is the last thing I see happen before the game freezes (CPU usage plunges to Zero and stays there).

Error.png


It seems to be 100% related to resistors as that text seen below is the last thing I see every time before the game freezes. Never had this before -- no freezing on AI turns they obviously are having resistors being quelled too as there are numerous wars going on. Thought my save was corrupted so I used an autosave, same issue, can (randomly) move forward, but eventually one of these resistors messages pops up and freeze. Now perhaps it has something to do with my specialists? In theory as if the city is too unhappy the citizen will become an entertainer, which in this mod has a severe malus to corruption (for this faction), thus perhaps it would make -gold??? Would that crash something? Is that possible? The specific specialist would produce two luxury (+2) and produce -2 corruption (i.e. corruption gets worse). Can that mess things up? I've not changed these settings, no issues in any of my other games, but I've not specifically tried this faction.

Error2.png
 

Attachments

Last edited:
I have an unusual error in which at the end of the AI turn and as the game is cycling through the initial city builds (showing units built that turn and cultural expansion that turn), then the game just freezes...
Seems to happen after all resistance ends in a city.
There's nothing in your config file that looks to me like it could cause a problem, and right off hand I can't think of any way the mod interacts with resistance ending. Could you post a save? I doubt I'll be able to figure this crash out without one.
 
Greetings and a Happy New Year with health and joy! :)

Some suggestions:
1. I'm interested in a setting (maybe optional) so that the AI doesn't consume all citizens in cities, meaning to have a limit, in case I want to set that military unit or certain buildings to "consume" one or more citizens when they are "produced"!!
For example: to build a tank unit, maybe three or four citizens should be "consumed" - as many people as there are in a tank crew!
2. I would go even further, in that units "produced" by a city should also be maintained with food by the city that "produced" them, or be subtracted from the "country's" food total!
- can a food total be set as well as a money total? So that the army can be maintained with both money and food?
- I think, maybe this is where the Distribution Hub District will show its true potential!
3. Could a building, for example a bakery, convert some of the raw food into bread and money?
- and this bread, to feed more people?
Can it appear, as an image, like a "bread food" or to appear more "food units"... maybe of a different color?
Can animal farms function in the same way...

Is such a setting possible?

- I think the strategy would be different... maybe closer to reality...

Thanks for your attention and understanding!


ps (sorry if these ideas have already been posted)
 
Last edited:
There's nothing in your config file that looks to me like it could cause a problem, and right off hand I can't think of any way the mod interacts with resistance ending. Could you post a save? I doubt I'll be able to figure this crash out without one.
Huge thanks Flintlock!
 

Attachments

@Flintlock

I have a simple request, of course I dont really know how simple it might be... or not!

For modding purposes of course. Im trying to implement a concept that revolves around citizen stats by changing our perception of happiness, production, science, commerce, pollution, and corruption through redefining by renaming, textures changes. Im making it more about the citizens rather than city output by visualization.

An example of this would be renaming and texturing the mentioned above into concepts including but not limited to citizen nutrition, "actual" hunger, intellect, and energy. It's mostly graphical in a believable way.

That being said I'm utilizing corruption as my citizen hunger or nutrition bar. This is where vanilla gameplay starts changing. Corruption/nutrition is modified to be high, or low if you are looking at it from a nutritional standpoint. The waste of it is perceived as inefficiency in citizens due to low nutritional/hunger value. As you get luxuries/foods that allow certain "buildings", which are in practice boosting nutrition by lowering corruption, then your citizens become more efficient. Corruption is modified to increase with every new citizen to resemble a sort of hunger and the need to get more foods/luxuries and bonuses to account for the new citizens that need to be fed quality foods, as they cant be effective surviving off just regular vanilla bread.

Hopefully you can see the picture and now my simple problem:

Corruption does not exist in the Capitol city no matter how much I try. Would it be easy to allow the Capitol to experience corruption? If not I will have to do some Capitol bldg tied nerfing that will make it too complex for my liking involving Capitol tied blds that obsolete, small wonders and stuff.
 
Some honorable mentions (not priority) that could help too are ability for blds to add shields to production not by percentage but exact number of shields per turn and also for all other stats (science, commerce, food, corruption).
 
Back
Top Bottom