1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Constant Stupid Ai Early City Placement

Discussion in 'Civ4 - General Discussions' started by DrewBledsoe, Jan 22, 2008.

  1. TheLastOne36

    TheLastOne36 Deity

    Joined:
    Jan 17, 2007
    Messages:
    14,045
    Woah, How'd you get your city to pop 17 by 1050 AD?

    i can only do that with a specialist economy in the Reinassaince era, and your running on a CE.
     
  2. DrewBledsoe

    DrewBledsoe Veteran QB

    Joined:
    Nov 6, 2005
    Messages:
    2,634
    Location:
    Cheering For Mr Sanchez
    Its marathon speed, that probably helps a bit. Just don't ever whip your core cities after the very, very early days, and have a couple of food sources each, easy really ;)
     
  3. Roland Johansen

    Roland Johansen Deity

    Joined:
    Apr 29, 2003
    Messages:
    4,292
    Location:
    the Netherlands
    You're right, I don't see the whole picture here, so I can't really judge it well. But I'm really not that picky about city locations. Or to say that more precisely, I'm not that picky in the long run. In the beginning, I'll pick the prime locations.

    I have city razing switched off, so I don't have a choice. I'll have to live with the city placements of the AI...:(

    What actually would be needed to fix this would be some kind of conservatism programmed into the AI. If two improvements are valued almost equal and one of those has already been constructed on the tile, then leave it as it is. That might avoid some of the removing and rebuilding of cottages by the AI. It's especially bad in the case of cottages.

    I agree with that. I'll see if I can find some situations in the game that I just started.

    But it's not that easy to improve it. City placement has become a harder decision in civilization 4 compared to earlier versions of civilization. There are lots of factors which should have an influence on the decision.
     
  4. Still_Asleep

    Still_Asleep Warlord

    Joined:
    Apr 5, 2006
    Messages:
    152
    Location:
    Vienna, Austria
    There is one big flaw with the AI evaluating the land:

    It checks for the maximal amount of ressources in the BFC, but it does NOT check whether or not these ressources are already occupied.

    The city Uppsala in the 2nd screenshot is a good example: 2 goldmines within the BFC, and the city could grow at least a bit with possible farms at the river. Theoretically a good spot. However, the fact that both goldmines are already occupied by Nidaros is ignored. To make matters worse, Uppsala does indeed get both goldmines as they are closer, but cant work them because it cannot grow - all but 1 possible farmspots belong to Nidaros. Nidaros lost the goldmines, the Vikings doublefuc.ked themselfes. Happens all the time.
     
  5. DrewBledsoe

    DrewBledsoe Veteran QB

    Joined:
    Nov 6, 2005
    Messages:
    2,634
    Location:
    Cheering For Mr Sanchez
    Sounds a very sensible idea. Maybe even something like (in the case of cottages)----"Is city growing, with a standard 2:food: surplus". If true then do not alter tile".....obviously that's quite a gross simplification.

    Thanks, much appreciated..:thumbsup:

    Very true. Its hard to do but some small changes would benefit immensely (idea here)

    I just looked back at that Uppsala screenshot, and had forgoten what an awful build that was. Following on from the point from (idea here), there really just isn't any room or any point to a city in Uppsala's location. If the founding code doesn't take into account resources already used by another city, then in should.It needs to somehow look at that spot and work out that there just isn't any room for a city there.(ok maybe in the late game when all the world has been settled, but especially not when there is still acres of free land available)

    It also needs some kind of check when valuing a city spot, where water tiles, unless they have seafood, count less than land tiles (but not desert or mountain). If tiles are to be shared with another city, these tiles shouldn't count towards the value of a new city spot...

    Anyways, just some ideas....as RJ said above it really is quite tough to come up with a definitive rule set:crazyeye:
     
  6. Tephros

    Tephros Caffeine Junkie

    Joined:
    Apr 12, 2006
    Messages:
    521
    Yeah, ideally your cities should be 5.5 apart on good land so that they all have their own city radius with no unused tiles or overlap. In the short run this is good because it limits the # of cities maintenance per territory acquired, without contributing excessively to city distance maintenance. On the other hand, more tightly grouped cities can do more research and production when populations are limited. Furthermore, having a continuous empire is still secondary to acquiring more resources. In the long run, there is a slightly different quid quo pro. As you acquire more technology, each city does better because it has more infrastructure, trade routes, etc. Two mediocre cities with significant overlap might be better than or equal to 1 good one in the same place, provided one doesn't take all the production while the other takes all the food, or something stupid like the examples mentioned. But in many cases I suspect that two cities that share 4 tiles could reach higher production while the single city could do better at research. This is because while they may not be able to reach 20+, they can build factories, coal plants, etc. without sacrificing potential population points.

    I don't know a lot about programming, but instead of looking at each tile and ignoring existing cities, the ai should consider the impact of the new city upon its own old cities, and match up tiles that complement each other well, like gold and fish, in considering how good a location is.

    One thing I never want to see again is cities placed 1 tile from the coast, that is just ********.
     
  7. Incan Emperor

    Incan Emperor Warlord

    Joined:
    Dec 28, 2007
    Messages:
    226
    The spot you picked sucks just as bad, 6 water tiles, water in both sides, but no coast, no ligthouse, no harbor, no customs house.
     
  8. JujuLautre

    JujuLautre Deity

    Joined:
    Apr 9, 2007
    Messages:
    3,112
    Location:
    Kansai, Japan
    think you're wrong; the shape of the coast makes me think that there is a coast tile SW of the red circle.
     
  9. DrewBledsoe

    DrewBledsoe Veteran QB

    Joined:
    Nov 6, 2005
    Messages:
    2,634
    Location:
    Cheering For Mr Sanchez
    Yep, Correct
     
  10. Incan Emperor

    Incan Emperor Warlord

    Joined:
    Dec 28, 2007
    Messages:
    226
    Sorry, just goes on to prove how little can be guessed with limited information, I could see 7 of the 8 surrounding tiles and still got it wrong, I guess the picture the AI takes into account when picking its city spots is just as limited as the one we had to work with.
     
  11. BalbanesBeoulve

    BalbanesBeoulve Emperor

    Joined:
    Jan 6, 2008
    Messages:
    1,060
    Nope. The AI even knows where resources are before they discover the tech needed.
     
  12. azzaman333

    azzaman333 meh

    Joined:
    Apr 9, 2005
    Messages:
    22,877
    Location:
    Melbourne, AUS Reputation:131^(9/2)
    That is no longer true.
     
  13. 50_dollar_bag

    50_dollar_bag Imitation Louis Vuitton

    Joined:
    Jun 13, 2005
    Messages:
    977
    Location:
    36 52 S 174 45 E
    Some of the dumb cities posted so far at least have some merit, but I struggle to see any point in this city barring the Great Lighthouse or a cultural win. But I don't think either of those apply.
     
  14. DrewBledsoe

    DrewBledsoe Veteran QB

    Joined:
    Nov 6, 2005
    Messages:
    2,634
    Location:
    Cheering For Mr Sanchez
    Its pretty pointless, but at least sensibly spaced;) ....the land in that SE corner is pretty bad (although one on the se tip good take in the crabs, build a lighthouse, then work both Gold mines at size 3 with a slow 1:food: growth, and come to think of it, it wouldn't be a bad little city)...

    The site for Ellasar, to my mind comes under where the ai needs a "just forget about this bit of land its useless" clause...with again the priviso that almost ANY land becomes tenable in the late game.

    And on a more thorough look at your map, that actually seems to be one of the only places left unsettled in the whole world, so it doesn't really fall into the category "of bad early cities", nor is it badly aligned with existing cities, its just a hopeless piece of land ;)
     
  15. Roland Johansen

    Roland Johansen Deity

    Joined:
    Apr 29, 2003
    Messages:
    4,292
    Location:
    the Netherlands
    Which city? There are many cities in that screenshot and you don't name one.

    Do you mean Ellasar? It's a poor city, but I would definitely found a city on that coast at some point in the game to harvest the commerce from the coastal tiles in that area. With further commerce income from trade routes, it could give a small commerce bonus (and thus science bonus) to your empire. I would probably build a city near the gold mines and crab first. It's a far better location. But in the end, a city on that coast where Ellasar has now been founded would also appear in my empire.

    Why would you never found a city there?
     
  16. 50_dollar_bag

    50_dollar_bag Imitation Louis Vuitton

    Joined:
    Jun 13, 2005
    Messages:
    977
    Location:
    36 52 S 174 45 E
    Sorry yes I did mean Ellasar.

    I'd never place a city there because I doubt it would ever end up coming out on top. An empire the size of Hamurabi's would probably have number of cities maintenance at 6 plus whatever the distance to palace maintenance is. I'm not a good number cruncher so I'd just never settle it rather than figure out if it would come out on top, I'm lazy like that :).

    Anyhow I like to have at least 1 decent tile in a cities BFC :lol:

    Reading through the thread it seems that you guys have done a good job of figuring out the AI city placement algorithm, and it seems the city was placed there because it was closer to the capital than the potential 2 gold + crabs + the off screen fish tile.
     
  17. Roland Johansen

    Roland Johansen Deity

    Joined:
    Apr 29, 2003
    Messages:
    4,292
    Location:
    the Netherlands
    The only thing this city really needs is a lighthouse, otherwise it can't really grow. That could be slowly produced from the hammers from a mined desert hill. With certain civics it could be rushed. Other useful buildings would include the harbor, the granary and the courthouse. With it's very low hammer yield, you can't expect to ever get more in that city than those buildings.

    But at this stage in the game, I guess it would be profitable from the moment it has been founded. Lets assume that its city upkeep is around 8 or so (distance + number of cities) and it increases the civic upkeep by 2, then it would need to have a commerce yield of 10 to be profitable. With the number of trade routes available with foreign civilization at this stage of the game, it would easily get 10 commerce. And from that moment, it will slowly, very slowly increase in income.

    It's of course an awful city, but it will bring a low profit so it's better to have it than not to have it. If the 150 hammers from the settler could be invested in something better, then of course it's a bad idea to found the city. It's likely that there is a better investment than the settler, but it's not a totally useless investment. It will bring a low profit.
     
  18. 50_dollar_bag

    50_dollar_bag Imitation Louis Vuitton

    Joined:
    Jun 13, 2005
    Messages:
    977
    Location:
    36 52 S 174 45 E
    I think it's unlikely to get a foreign trade route until it's bigger than size 1, and the game is in the Mercantilism era.

    The hammers could have been spent on the gold/crabs site, which would be profitable a lot sooner.

    Let's not debate too much on whether it's a worthwhile city, it's already cost my employer a considerable amount of profit :p
     
  19. DrewBledsoe

    DrewBledsoe Veteran QB

    Joined:
    Nov 6, 2005
    Messages:
    2,634
    Location:
    Cheering For Mr Sanchez
    I'm certain you know already RJ, and you are the Math whizz, but it would also increase the cost of each and every other city marginally too. Its the kind of city that desperately needs Sushi and Mining Corps, then it could grow and produce, but as we both said, for similar reasons, almost anywhere with free land can be useful in the late game..
    I especially want to bring up this (my bold) point. If the ai wants to build a city then that site, any human can see, is many
    times better (especially if it can take in unseen fish out of screenshot as you said)....

    This was one of my original main points, building cities in very poor/cramped locations, when half a dozen tiles further away is a decent spot (fairly in this case)....

    So your screenshot actually DID illustrate a problem, so :goodjob:
     
  20. Quartz

    Quartz Chieftain

    Joined:
    Aug 29, 2007
    Messages:
    8
    Sorry to ask an irrellevant question...
    but those little face icons (obviously mentioning relations), do they come with a patch? wich one?
    i've never seen them before
     

Share This Page