Modding "Sparse" to actually be so.

Hormagaunt

Warlord
Joined
Oct 3, 2010
Messages
212
I found on the web how to decrease the distance between cities.
I found how to increase the distance between civilizations.
I found how to increase a city's footprint (how far it'd use land).

What I need to find out is how to make "Sparse" actually sparse.

A long time back I was able to select "Sparse" and each civ would get 2 (two) resources near it's capital and no resources anywhere else in the game. That was actually fun (well, for me anyway) but maybe a bit *too* sparse.

What I'd like to know is where in the XML or LUA code can be found "how sparse is sparse". Does anybody know?

Moderator Action: Moved to C&C forum. leif
 
Last edited by a moderator:
You need to look in ResourceGenerator.lua (Civilization VI --> Base --> Assets --> Maps --> Utility).

The relevant bit of code is near the top:

Code:
function ResourceGenerator:__InitResourceData()

    self.iResourcesInDB = 0;
    self.iLuxuriesThisSizeMap = GameInfo.Maps[Map.GetMapSize()].DefaultPlayers * 2;

    -- Get resource value setting input by user.
    if self.resources == 1 then
            self.resources = -3;

self.resources ==1 is the setting for Sparse, and self.resources = -3 is the effect of sparse. You'll want to make -3 even lower to decrease the amount of all resources that spawn.

Note that this value isn't a specific number of anything, it just tells the game what to take away from or add to the standard percents of luxuries, bonus, and strategic resources.
 
Thanks. Also, turns out that I got the "only two" by selecting "Resources NONE". Sparse is still way too populous. I'll try changing the item you show.
 
Back
Top Bottom