How does <Rarity> work (for lairs and world resources)?

I would have guessed that half the <Rarity> means half as often spawned but in practice the behavior just seems completely odd. Can anyone give me some clarity on how i can accurately control how often something is spawned?

 

5,439 views 3 replies
Reply #2 Top

Although I haven't experimented a lot with this, I'd think you'd get a bit finer control over resource frequency using this tag:


        <MinPerPlayer>1</MinPerPlayer>

I see .25, 2 and other values assigned in the CoreResources file for the resources that actually include this tag (Iron Ore, etc.).

Looking over the link Heavenfall is posted, while Rarity can be used to increase one resource's chances of getting 'picked' over another, it's still a lottery situation, so just because one has a rarity of 300 and another has 100, that doesn't mean you'll end up with 3x one resource over another, or even if a given resource would appear.  The MinPerPlayer tag should at least ensure getting a resource on the map if I understand the purpose of that tag correctly, but I haven't done an inventory lately.

A quick way to check would be to tweak your numbers, then reveal map on turn 1 using a cheat code, a +30 sight range to your playtest Sov or some such.  Then count off the resources, compare against the number of players, and see if the MinPerPlayer rule is being followed or mostly followed... (i.e. I have 8 sovs on this map, min Iron ore is 2 per player, so there should be at least 16 iron ores...)

I did something along these lines in my attempts to add a resource (which I ended up not needing after the fact), and while my own resource never appeared on map, I was able to see if I had changed the other resources in some fashion.  Wasn't doing a resource count at that point, though...

Reply #3 Top

Also, because of how probability works.

If you have 10 resources with 200 rarity, the odds of finding any 1 resource should be roughly 1/10.

If you have 9 resources with 200 rarity, and 1 resource with 100 rarity, the odds of finding that last resource is something like ~0.02%.