Finding new Resources when mining?

woodelf

Bard
Retired Moderator
Joined
Jun 12, 2003
Messages
15,036
Location
Gallery
After 2 weeks of playing I just noticed that when you hold the cursor over an area that can be mined it tells the amount of turns, ect but also says that there is a small chance of finding copper, iron, silver, and gold!

My questions are; has anyone actually had this happen? If I have I haven't noticed. If it does happen, maybe the message should be more obvious.

Has anyone located where in the coding the % chance of this happening is? I'd love to tweak that a bit higher!
 
Did you get a very noticeable message?

I'm going to dig into the XML and see if i can tweak mine. Any help pointing me in the right direction welcome!
 
I found something that might control the odds of finding something at random with a mine. This is in CIV4ImprovementInfos.xml under the IMPROVEMENT_MINE section.

<BonusTypeStruct>
<BonusType>BONUS_COPPER</BonusType>
<bBonusMakesValid>1</bBonusMakesValid>
<bBonusTrade>1</bBonusTrade>
<iDiscoverRand>10000</iDiscoverRand>
<YieldChanges>
<iYieldChange>0</iYieldChange>
<iYieldChange>1</iYieldChange>
<iYieldChange>0</iYieldChange>
</YieldChanges>
</BonusTypeStruct>

There are sections like this for Aluminum, Coal, Copper, Gems, Gold, Iron, Silver, and Uranium.
 
I got the same pop up you get when a new resource like iron comes up (if I remember correctly). It happened in the second game I played. Have not seen it since. What I discovered was stone, I remember very distinctly because it gave me marble and stone in my capitol. woot! What a waste of a game on noble. I built almost every wonder in that game. I sure would like to see it on Emperor though.
 
Thanks Roma. I'll look into tweaking that number.

Dom - I like the way your mind works. That would be great in a fantasy mod.
 
At what diff level Alex? I've played a lot in 2 weeks and found none. Damn.
 
Update - I changed the number 10000 to 100 for gems in

<iDiscoverRand>10000</iDiscoverRand>.

Obviously that was a huge change in magnitude, but I wanted to see something, which I did. I made 4 mines and saw no messages right away. I did, however, get a "you have discovered gems" message 20 or more turns after the fact! Wierd. I'll tinker with this number since 100 is way too frequent.
 
woodelf said:
did, however, get a "you have discovered gems" message 20 or more turns after the fact! Wierd. I'll tinker with this number since 100 is way too frequent.

What this looks like to me, then, is that each mine has a 1 in X chance each turn of discovering each mineral. If X=100 and you have 4 mines, you'd expect to get a new gems after a median of 25 turns, which matches pretty well to what you saw.

So, if X=10,000 (the default), and there are four resources in question, and the game lasts 500 turns, you should expect each mine to have a ~20% chance of finding a mineral in the course of a game. Or, looked at a different way, if your empire has maybe 20 extra mines, after 50 turns you should expect about a 40% chance of having had one of them find something new. Note that I said "extra" mines; if you placed a mine on one of the eight mineral resources, of course a new one won't pop up.

Maybe that's why some people haven't been seeing this often; they're probably only building mines when there's something specific to mine. The AI makes this mistake; not enough mines for production, instead preferring to make tons of cottages. Now, I suppose you could up the percentage a bit, but don't change it too far, or else every mined tile will get a resource and be better than a cottage/hamlet/village/town.
 
I build mines whenever I can. Occasionally I have to build windmills instead if the city is low on good farmland. So far I've seen mines discover resources in two games, a total of three times.

Spatz's calculations are a bit off... A single mine has about a 0.5% chance of discovering a new resource during 50 turns. This makes the chance 9.5% for 20 mines. If you build 140 mines (that's 7 cities with only mines around them) you'll have a 50.4% chance of discovering something in those 50 turns.

The median for the X=100 and 4 mines case is in fact only 17 turns, which still matches pretty well with the empirical results.
 
Spatzimaus said:
Maybe that's why some people haven't been seeing this often; they're probably only building mines when there's something specific to mine. The AI makes this mistake; not enough mines for production, instead preferring to make tons of cottages. Now, I suppose you could up the percentage a bit, but don't change it too far, or else every mined tile will get a resource and be better than a cottage/hamlet/village/town.

This sounds correct since I work mines whenever I can't do a specific tile improvement.
 
I've taken to mining every hill that's in my cultural border but outside my workable tiles. It's a free chance at a resource.
 
I'm not so sure about that. I think you have to be working the tile to find resources.
Can anyone confirm or deny that?

-RdF
 
So the calculation is per turn then. That makes sense. I can see that my tweaking needs further tweaking....
 
roidesfoux said:
I'm not so sure about that. I think you have to be working the tile to find resources.
Can anyone confirm or deny that?

-RdF

I've found resources on tiles I wasn't working and weren't within a city's workable radius. That's why I do it ;)
 
Back
Top Bottom