Marble Wonder Bonus

Carazycool

Warlord
Joined
Feb 25, 2007
Messages
249
Location
MA
If marble is within the 3 rings of multiple cities, how does the game determine which city gets the wonder production bonus from having marble?

I am playing a game as India. I purposely bought some tiles in Mumbai to gain access to the marble, hoping to give Mumbai the wonder production bonus to build Petra. As you can see in the screenshot, the marble is 3 rings away from Delhi, but I bought the tile using Mumbai's "buy tile" option. Still, the wonder production bonus was granted to Delhi instead of Mumbai. How is this determined? My hypothesis is that the wonder production bonus is granted to the first city that is planted within 3 tiles of the marble, regardless of which city eventually takes control of the tile. Does anyone have any insight about this?

 
Which city is working the Marble tile Mumbai or Delhi?

If it's Delhi then it probably depends on which city is working it. If it's Mumbai and you still are not getting the bonus, then it probably means which city is closer. In this case both cities are 3 tiles away, but the capital probably gets the advantage because it was founded first.
 
I purposely assigned Mumbai to work the marble tile, but it still gave the bonus to Delhi.
 
It's what city owns the tile(what city bought it with :c5culture: or :c5gold: ), and you don't have to work the marble to get the bonus. The same applies to building stables and forges, but not obtaining the bonuses(same for Petra).
 
But, here, he said Mumbai bought the tile with gold, but Delhi is getting the wonder bonus, not Mumbai.
 
Whichever city puts a pink ring around the tile first. That is, the city that first considers expanding its boarder into that tile.

I had a game where Mecca was near marble, but Medina was thinking of grabbing it. So I bought the tile with Mecca, but Medina still got the bonus.
 
Whichever city puts a pink ring around the tile first. That is, the city that first considers expanding its boarder into that tile.

I had a game where Mecca was near marble, but Medina was thinking of grabbing it. So I bought the tile with Mecca, but Medina still got the bonus.

This isn't a hard-set rule either. I just tested it with Egypt. Thebes was 3 tiles away from a Marble and had the pink ring around it (2 turns from annexing it). I settles Memphis 3 tiles from the same marble, bought the marble tile with Memphis, and got the wonder production bonus in Memphis. Got the notification pop-up and everything.

All of my experience playing Civ V has led me to believe that whichever city first claims a tile within its workable radius is the one that gets credit for having that resource "near" the city. The only time I've ever seen otherwise was when using a worldbuilder scenario, and I think that might have been a bug because there were other odd issues with that scenario.

I had actually just written a blog post about this rule because I've seen other questions about it on forums, but it looks like that blog may be erroneous. I guess I'll have to revise it and re-post it...

so I'm kinda stumped by this post...
 
As pure speculation, I just want to throw in that there might be other factors determining this for all we know, such as tile location relative to city location. What I have in mind is the issues we know arise for instance with range 3 units when attacking into third ring beyond a forest and how game will think some tiles are covered while others are not, although in fact the tiles are equally covered (or uncovered). What I'm getting at is game's path-finding algorithm into third ring seems somewhat bugged, and it might be that the distance calculation from Marble plot to nearest cities come out erratically - so that in this case, Delhi is deemed nearest city, not because it's the capital or was settled first, but just because of the geometry of its position relative to the Marble.

There was a thread a long time ago discussing the ring-3 pathing issue with focus on English Longbowmen, but I'm not sure if I can locate that thread.

Edit > Can't find the thread I had in mind but post #3 in this one touches on a bit of the same problem.
 
According to the source code - CvPlot:: DoFindCityToLinkResourceTo() - it's the nearest city to the plot, which is not necessarily the one that acquired the plot. In the case of a tie, it will be the first city found (but you'll need to decode the spaghetti logic in the plotCity() function - in CvGameCoreUtils.cpp - to work out the order)
 
Whichever city puts a pink ring around the tile first. That is, the city that first considers expanding its boarder into that tile.

As you can see, Delhi never even came within 1 tile of the marble, so there is no way that a pink ring was ever around the marble for Delhi.

I believe it is to witch city this tie belong by expansion or bought

I bought the tile with Mumbai but Delhi got credit for the marble.

According to the source code - CvPlot:: DoFindCityToLinkResourceTo() - it's the nearest city to the plot, which is not necessarily the one that acquired the plot. In the case of a tie, it will be the first city found (but you'll need to decode the spaghetti logic in the plotCity() function - in CvGameCoreUtils.cpp - to work out the order)

This is about as good of an explanation as I can think of.
 
According to the source code - CvPlot:: DoFindCityToLinkResourceTo() - it's the nearest city to the plot, which is not necessarily the one that acquired the plot. In the case of a tie, it will be the first city found (but you'll need to decode the spaghetti logic in the plotCity() function - in CvGameCoreUtils.cpp - to work out the order)

Great somebody confirmed through the source code. It seems I was right all along. The city that is the closest gets the bonus or some resource as part of its territory. It's just in this case that both cities had the same tile radius but since capital was planted first that city got the bonus. So in that case it depends on which city was planted first.
 
Great somebody confirmed through the source code. It seems I was right all along. The city that is the closest gets the bonus or some resource as part of its territory. It's just in this case that both cities had the same tile radius but since capital was planted first that city got the bonus. So in that case it depends on which city was planted first.
No you are reading the post wrong. It's not the first city founded, it's the first city found. So game will use whatever weird algorithm to search for cities around the resource, and whatever city it finds first will be the one that gets the resource. This may be the city founded first (as in this case), but it may also be another city (see Megabearsfan's post #8 above).
 
hmmm. I'm tempted to replay the save and put my first city where Mumbai is and the 2nd city where Delhi is and to see which city it gives credit of the marble to.

edit: nevermind :-/ the autosave is gone. dernit.
 
Top Bottom