How to redistribute resources on custom map


Jan 16, 2004
I like to play on pre made maps modified using the world builder and use a Custom set of map (lua) files. I'd like to alter the map and the redistribute resources again afterwards.

The built-in scatter resources button from world builder doesn't seem to do this properly though (seems it uses other distribution rules, many vanilla).

Does anyone know if/how you can run manually AFTER the terrain has been modified so that resource distribution follow the resource distribution rules/pattern from my mod.

Pretty inexperienced with lua.

If your custom map has the Randomise Resources option ticked, after the map is loaded the game engine will call the AddResourcesForWorldBuilderMap() function in the WorldBuilderRandomItems.lua script, so in theory you could over-ride that, but ...

... see also, the RandomAfrica.Civ5Map and how that is set up to call the PostProcessAfrica.lua script (which manually calls the AddResourcesForWorldBuilderMap() function) - from the top "Mod Data" tab
Top Bottom