The Problem With Sprawling

i noticed there was a slight increase in sea resources from 30 to 32, but given that theres 2/3 the number of sea resources reachable now, perhaps it could use a higher amount (pearls are added but oil is gone so they cancel out), like 30*3/2=45 to compensate
 
And there's the obvious answer y'll were missin. Now, I spose someone will say, "Why do we have to select the 'Blessings of Amathaon'? Why can't you jus remove sprawlin?" Why can't people jus accept certain things and quit whinin? I'm pretty sure Kael has to answer tons of useless threads like this. And I doubt he finds it refreshin. If everyone used their heads and the pedia, we wouldn't get threads like this.

Please try to be nicer in your replies. I certainly dont mind anyone pointing out questions or concerns they have with the game, thats why we created the forum.
 
No, that was a good observation MaxAstro which has enlightened my understanding of the bigger picture. Thanks for the thread. Thanks for the revealing response Kael.
I've had also been wondering about the starting positions in 32, it used to be certain that I would start with nice resource bonuses for my starting city, now I've often got to go find them. This has also changed my strategy in beelining to the opponents capitals, which are not always the sweet target they once were ceratin to be.
 
Unfortunately it seems the clean and simple answer is, as Kael basically said and others have implied, there's no way to fix these issues without removing Sprawling, which I don't want to happen. It would be nice if #2 and #3 could be fixed (#1 is partly counterbalanced by the increase in the normalization range, I suppose), but they certainly aren't game-breaking enough to warrant removing Sprawling. I don't think Blessings is a 100% fix, especially for #1 and not at all for #2, but it's a valid point.
 
the third tile is only a problem with spawns because capitols have a minimum threshold for how good they are. if the third row is counted, the whole delicate balance process could be thrown out of wack. maybe as much if not more than the bug that placed excessive amounts of trees(and less resources).
you did fix that, right?


unreachable water resources are only problem because they annoy people thats why the game normally wouldn't spawn them in the first place.
 
Making the best-spot-for-city calculation include the 3rd ring for all civs cause severe problems for the AI, since the AI will follow the best-spot-for-city suggestions without any further investigation meaning that what might be a best-spot for a city with 3 rings it is more often than not less than optimal for a city with just 2 rings (to the point of being completely useless).

I often see the non-Kurioate AI civilizations start out severely crippled from founding their capitol city on a city spot that would only really work with 3rd ring available - while Kurioates surge ahead in every game.

The solution would simply be to only include 3rd ring in best-spot-for-city calculations when the Kurioates civilization is directly involved.
 
Making the best-spot-for-city calculation include the 3rd ring for all civs cause severe problems for the AI, since the AI will follow the best-spot-for-city suggestions without any further investigation meaning that what might be a best-spot for a city with 3 rings it is more often than not less than optimal for a city with just 2 rings (to the point of being completely useless).

I often see the non-Kurioate AI civilizations start out severely crippled from founding their capitol city on a city spot that would only really work with 3rd ring available - while Kurioates surge ahead in every game.

The solution would simply be to only include 3rd ring in best-spot-for-city calculations when the Kurioates civilization is directly involved.

I wouldnt say that it is simple, but I think your right. Its all a part of improving the AI, which we've started doing (we tackled military strategy first) but we will cover features like this as well. typically this just helps the Ai, but in this case it should help the humans a little bit too because the "computer recommended" city sites should become more accurate.
 
I think it is more simple than you realize. I noticed some time ago (looking at your code) that you made the number of workable city plots include the 3rd ring by default and then in some of the checks you switch it back to only include 2 rings.

It should be the other way around to avoid the current problems - keep 2 rings the default and only increase to include 3rd ring when Kurioate is involved.

I am assuming you made this change to make it easier for the AI to handle the Kurioate work properly (without too much extra coding required), but the side effects is causing serious problems for AI when trying to handle all of the other civs.

Wouldn't you agree that it would require less work to switch back to the original working plot/ring number and then including custom functions to handle 1 civ - rather than keeping the current way and having to add work arounds for all the rest of the civs? :)
 
I think it is more simple than you realize. I noticed some time ago (looking at your code) that you made the number of workable city plots include the 3rd ring by default and then in some of the checks you switch it back to only include 2 rings.

It should be the other way around to avoid the current problems - keep 2 rings the default and only increase to include 3rd ring when Kurioate is involved.

I am assuming you made this change to make it easier for the AI to handle the Kurioate work properly (without too much extra coding required), but the side effects is causing serious problems for AI when trying to handle all of the other civs.

Wouldn't you agree that it would require less work to switch back to the original working plot/ring number and then including custom functions to handle 1 civ - rather than keeping the current way and having to add work arounds for all the rest of the civs? :)

Its all relative I suppose. When you say its currently causing serious problems you are talking about picking plots that arent as ideal for city locations, resources spawning in places normal civs cant get to, etc. Done the other way (kept at 2 and increased to 3 where needed) causes CtD's when any function tries to interogate a plot that isn't in the list. So I opted for non-optomized over crashes, with the understanding that Id rather do work to optomize rather than fix ctd's.

The real crazyiness is the city plot order functions. Im sure you've looked at them, but they are a pain in the butt to consider for 2 different ring sizes. In short the game orders the plots a round a city 1,2,3,4... where 1 may be the plot 2 west and 2 north, 2 may be 2 west and 1 north, etc (i forget what the actual order is). A 3 ring city would still have 1,2,3,4... (though it goes on for longer) but 1 maybe 3 west and 3 north, 2 would be 3 west and 2 north, etc.

That doesnt sound to bad until you start mixing functions with one function using the 3rd ring model and one using the 2nd ring list. The first function could trigger when something occurs in plot 12, then call to another one to do something in plot 12 that is using 2 ring numbers and comes up with a different plot. Which could cause all sorts of issues.

Add in the fact that the number of city plots is called over 150 times in different places in the code and it becomes (at least to my programming skill), a significant challenge. Not insurmoutable, but there is work to do.
 
That reminds me of the bug I noticed a long time ago, where a city with both the City Hub and Planar Gate buildings (cheating, of course) would spawn the planar gate units up and to the right of the city, which was often a water tile. I haven't tried to see if this still happens in BtS versions, but I suspect it might (except of course that City Hub isn't a building now). That could be a problem when the Sheaim build the City of a Thousand Slums, or if the Capture All Buildings (or Assimilation, if it is added) game option(s) allow the Kuriotates to get Planar Gates.
 
That reminds me of the bug I noticed a long time ago, where a city with both the City Hub and Planar Gate buildings (cheating, of course) would spawn the planar gate units up and to the right of the city, which was often a water tile. I haven't tried to see if this still happens in BtS versions, but I suspect it might (except of course that City Hub isn't a building now). That could be a problem when the Sheaim build the City of a Thousand Slums, or if the Capture All Buildings (or Assimilation, if it is added) game option(s) allow the Kuriotates to get Planar Gates.

Yeah, the City of a Thousand Slums adds an additional wrinkle into the code since we cant assume thi sis just a Kurio thing. Though for the AI it may be good to adjust its logic to the most common situation (2 ring cities).
 
Its all relative I suppose. When you say its currently causing serious problems you are talking about picking plots that arent as ideal for city locations, resources spawning in places normal civs cant get to, etc.
It is more serious than you appear to realize. More often than not it is outright crippling for the AI to constantly be choosing less than optimal(sometimes useless) city locations.

Done the other way (kept at 2 and increased to 3 where needed) causes CtD's when any function tries to interogate a plot that isn't in the list.
The problem appears to be that the default values (NUM_CITY_PLOTS and CITY_PLOTS_RADIUS) are also used for determining the size of the CityPlot arrays and FAssert checks as well as for any other ingame functions.

I would suggest returning these 2 global vars to their default value (so that the regular uses of them are normalized) and creating 2 new MAX_* global vars and replace the current vars with the MAX_* vars whereever they are used for array defining and FAssert.
 
While you are dealing with city placement, may I suggest that you somehow stop the AI from placing cities close enough to rivers and coasts to prevent other cities being built there but not close enough to take advantage of the river/coasts?
 
The city location advisor does seem bad right now, which seriously harms the AIs. To be honest, making the whole game worse for the sake of one civ and one wonder seems like a suboptimal outcome.
I know this is not intentional, but sacrificing playability for additional features doesn't seem like the way to go.

Anything that makes the AI inherently worse than human players at essential choices like city placement (which should be a trivial problem for an AI except for maybe border cities etc.) is a huge problem, but in this case this same mechanic also causes other problems...


What would happen if one would give all civs sprawling/the ability to work three rings, but all civs except for Kuriotates would get 0 yields on the third ring? Would this change the city placement advisor/AI city settlement preferences? Would the AI know that it makes more sense to let another city for a tile instead of working it yourself for 0 yields (which isn't even possible as far as I know)?
 
It is more serious than you appear to realize. More often than not it is outright crippling for the AI to constantly be choosing less than optimal(sometimes useless) city locations.

Maybe. My belief is that using non-optimal city placement is a lesser issue than crashes. But I suppose its a judgement call. ;)

The city location advisor does seem bad right now, which seriously harms the AIs. To be honest, making the whole game worse for the sake of one civ and one wonder seems like a suboptimal outcome.
I know this is not intentional, but sacrificing playability for additional features doesn't seem like the way to go.

Anything that makes the AI inherently worse than human players at essential choices like city placement (which should be a trivial problem for an AI except for maybe border cities etc.) is a huge problem, but in this case this same mechanic also causes other problems...

What would happen if one would give all civs sprawling/the ability to work three rings, but all civs except for Kuriotates would get 0 yields on the third ring? Would this change the city placement advisor/AI city settlement preferences? Would the AI know that it makes more sense to let another city for a tile instead of working it yourself for 0 yields (which isn't even possible as far as I know)?

Better to just fix the issue. The plan is to teach the AI to compensate for the FfH changes. We will get it worked out. If worse comes to worse and we cant fix the problem we will look at cutting features, but we arent close to that yet.
 
Maybe. My belief is that using non-optimal city placement is a lesser issue than crashes. But I suppose its a judgement call. ;)
The solution for both are not mutually exclusive - and I believe I already outlined the main reason for the CTD that you seem to have had some problems with.
 
Back
Top Bottom