Something is happening with these 2 options below.... They cannot both be true. One of the other, or both have to be false or game crashes.
Something else... This one is not a big deal because it's working the way I have it in bold below, but I used to just write [all] with the brackets and have no issues, but it started to crash this time around until I changed them to what's shown here.
I wasn't able to replicate these crashes by simply setting the config that way. Can you share more about your setup? When does the game crash, exactly?
Also I want to report a minor bug.
With modified retreat-rules "all-units" or "if-faster" it is possible for units flagged "immobile" to retreat. This makes it possible to push immobile units with more than one hp across the entire map (if they heal one hp every turn). This is strange, for example, with pre-placed immobile units in some scenarios (bunkers or similar). Is it possible to check if units are immobile, before allowing their retreat?
Fixed. Oddly, immobile units can retreat in the base game as long as they have more than one move. That's part of how that bug got in there, if the base game logic had considered the immobile flag, I would have seen that and considered it. The fix carves out an exception for immobile units so the all-units retreat setting doesn't apply to them. That way you'll get the base game behavior for them.
Would it be possible for the respawn ai character option on the game rules to spawn them but not spawn at war? In my experience this is more detrimental to the ai than the player.
Probably. I wouldn't know how to do it right off hand but that certainly sounds possible.
Out of curiosity, did you look into that? Is it easy to do or rather not?
I don't know what would be involved in adding a new player to an ongoing game. Transferring control of the cities would be easy, but I'd be worried about things like diplomacy since I don't have that data all mapped out so I might not be able to clear it properly for a new player.
Non-unlimited railroad movement: I understand this is possible, but I'm not sure how the INI logic works, particularly if it also affects regular road movement. Can road movement be left as is, and make railroads twice or thrice as efficient?
The railroad limit doesn't affect road movement. It can be used to make railroads work like faster roads, or work like in Civ 4 where they give a fixed movement distance to all unit types.
It's funny because I kind of thought that was part of your mods and I was already using the extended city radius as such a given, but it turns out I just forgot that wasn't the case when I switched from version 13 to version 20 and the game started crashing the first time I tried to move a unit. Turns out I had used version 13 back on Antal's original EXE and everything was compatible, or at least the game didn't crash on my attempts. But version 20 didn't seem to maintain that compatibility.
That's too bad about the incompatibility with Antal's edits. As C3X grew, it was inevitable that at some point they would conflict. Expanded city radius is something I could (maybe, no promises) add to C3X in the future. One of the reasons I haven't done it yet is that I think it would make more sense for the radius to expand only for cities beyond a certain size or with a certain improvement, but that's far more difficult than changing the radius for all cities. On the plus side, I could look at the edits Antal made and use that as a starting point for the feature. As I recall there was some bug with his implementation of the expanded radius that he never properly fixed.
This would be my first time commenting on this project, while following it for a while. I want to provide a bit of a controversial opinion on this, after reading a bunch of posts, especially recently. I believe this thread (and the efforts put here by it's sole developer) are getting exceedingly derailed by a lot of very narrow and, in some cases, just plainly weird requests.
There's some truth to this. Often I take on requests thinking they'll be quick and easy, but then a bunch of unforeseen issues come up and the request ends up taking a lot longer than I thought it would, delaying other things. A perfect example is the unit stack limit. It is simple to restrict units from walking onto overcrowded tiles, as I expected, but it turns out it's difficult to block the AI from airlifting, airdropping, and especially rebasing units beyond the limit.
It's much easier to prevent the human player since the player's actions are gated by various "can do X here" functions that I can edit. But the AI doesn't have any of those for airlifting, etc. so I have to edit some other part of the logic to prevent the AI from taking those actions. For example, for AI airlifting into a city, I can edit the check that the city has an airport to return that it does not if the tile is overcrowded. The real problem, though, is that I don't see anywhere I can easily edit to stop the AI from rebasing its aircraft. I'll have to think of something clever or edit the machine code directly, which is something I do only if I can't avoid it.
Meanwhile I've only spent one day working on the
32 MB save limit. What I've discovered so far is that it's unfortunately not an artificial limit like a buffer that can be expanded. The problem is simply that the game is running out of memory, and that shows up first as failing to save because the game tries to allocate a chunk of memory large enough to store the entire save file. In my test, it failed to allocate once the uncompressed save size reached about 36 MB. The game still had 100 - 150 MB of memory available of its entire 2 GB range, but couldn't allocate 36 MB due to fragmentation, i.e., there wasn't a large enough consecutive chunk of space available.
Next I started investigating where all the memory is going because I don't think the game ought to require nearly that much. I remember first playing Civ 3 on a Pentium 3 system with 128 MB of RAM, so the basic memory requirement for the interface, terrain, etc. must be pretty low. It's a question of what it's loading over the course of a game that's taking so much space. It can't be the game data itself since that's stored in uncompressed save files of only about 36 MB. It must be the art files, but doing some rough math, all the Art/Units folders from vanilla + PTW + Conquests sum to about 190 MB, and all the Sounds folders sum to about 240 MB. So even loading all of that at once wouldn't use up that much space. Although they would be decompressed after loading so would take up more space in memory than on disk, but on the other hand I know for a fact that the game only loads art assets for unit types that are on the map, so in practice the vast majority of them won't be loaded at all.
Poking around inside game's memory using VMMap, I noticed that many of its allocations were performed by jgl.dll and sound.dll, not the EXE itself. That's pretty annoying because I don't have those DLLs nicely decompiled and C3X isn't set up to modify them. I intercepted the EXE's calls to operator new and recorded all allocations done that way while loading a game. The EXE allocated a total of about 90 MB like that of a grand total 1700-some MB used by the process, so that reinforces that the DLLs are responsible for wasting so much memory.
BTW, all these numbers are for the save someone posted to this thread a while ago that was close to the limit. That save is a good example since it uses only the base game's art files, so that eliminates custom art right off the bat as a possibility for where the memory is going. I'm not sure what I can do, if anything, about the so-called 32 MB save limit (in reality it's not a limit and doesn't occur at 32 MB). The good news is that setting the Large Address Aware bit on the EXE allows it to use an extra gigabyte or so of memory and C3X already does that when you install it. I'd still like to investigate more to figure out where the memory is actually going, if only because I'm curious now.
Flintlock, I read a while back you were looking into dealing with some of the units which don't stack correctly in city or other menus. Currently, some of my units stack (XXXX regular unit x5) other times my units don't (YYYY regular unit; YYYY regular unit; etc.) Even with this issue, it is materially better than the base game (most cities would be a never ending scroll a few hundred turns in.
I don't know why the unit grouping wouldn't work sometimes. It's not something I've ever seen in my own games so I'll have to investigate. I know for AI units they'll sometimes be split into different groups because the unit types get duplicated to spread out AI strategies, but people are reporting other issues.
Also, would it be possible to have a building limit not tied to resources? So you want to build a barracks, you are allowed a base amount of 5, and then 1 per every 3 cities (similar to how unit limits work). Is this even possible without taking an overly burdensome amount of time?
That would be possible. It's easier to do now that I've implemented unit limits since the two would work similarly.