Flintlock
Emperor
- Joined
- Sep 25, 2004
- Messages
- 1,220
If it's possible to increase the city limit at all, doubling it will not be a problem. In fact, if I can, I'll quadruple it to 2048 just to be sure. That should allow for more than enough cities without consuming much memory, which is the limiting factor. The table of city connection info requires 4 bytes for each pair of cities up to the limit, so a limit of 2048 would consume 4*2048^2 = 16.8 MB, which is insignificant with 3 GB available. But increasing the limit to something crazy like 10k cities would consume 400 MB.Therefore, I wondered: is it possible to at least double this value? For example, from 512 to 1024 points.
By the way, the reason the game reserves 4 bytes = 32 bits per city pair is that it's reserving space for connection info for each civ potentially on the map. In other words, the game doesn't simply determine if each pair of cities is connected, it determines if they're connected through a route that's available to each civ in the game. The game evaluates city connections for each civ independently, which I think is one of the reasons it's so slow. It would be better if it could notice that two cities are connected by a route that's not obstructed by any units, because that's usually the case, and conclude that there's a route that's available to all civs in the game. Instead it rechecks for every one.
It's nice to see someone's putting this feature through its paces, too bad about the bug though. Thanks for reporting it. I thought I tested this for AI players but I'll have another look. Right off hand I have no idea what might be causing the bug, as far as I know the logic for which cities are allowed to build which units is the same for both the human and AI players.Ok I've got a weird bug with the new Buildings Prereqs for Units:
I deliberately programmed it so that buildings won't generate a resource that is still hidden behind a technology requirement. I'm curious, is that how you expected/want it to work? Because I could change it if most modders would prefer that buildings can generate resources before they're revealed by tech. I recall that's what @Civinator preferred, at least at first, when we discussed this back when I was first working on it. I added the tech restriction because in all the examples I could think of, it made sense for a resource to be harvested/mined first before it could be generated artificially.Testing the 'Buildings Produce Resources' feature: found that if a building produces a resource that is not yet available, that building will not put the resource into your trade network until you research the corresponding technology for that resource. Works well so far.