gunnergoz
Cat Herder
@Heinous_hat: What do I do with the .lua file?
@Heinous_hat: What do I do with the .lua file?
You need to put it in your maps directory. You can use the one in the user folder (e.g. C:\Users\...\Documents\My Games\Sid Meier's Civilization 5\Maps) for single player. For multiplayer, it might have to go in the game installation maps folder... not sure, I haven't played any MP with custom scripts.
You can do that with any custom maps or scripts so you don't need to go through the mod menu and load the map as a mod. It will show up in the regular map selection menu.
How do I decrease the amount of hills and mountains? There isn't much space to build on.
Try tweaking these variables a little (higher) in MapConstants
mconst.hillsPercent = 0.50
mconst.mountainsPercent = 0.85
You could also try simultaneously raising mconst.landPercent for more total land area, but not too much or land masses start to merge.
Also, bobert13's code in post #377 will place hills adjacent to mountains. If you combine both methods, you can create more contiguous flat space while still having convincing ranges of hills/mountains to settle beside for their benefits.
Thanks for your reply. I edited my post a bit while you were posting. I also wanted to know if I can get larger and more homogeneous continents instead of the slim fractals.
That worked quite well but it's hard to get two separate continents like in Terra. With a little luck you could probably get something similar though.
I have another problem. Since I reduced the number of mountains I get snowy hills in the middle of warm regions. What's up with that?
I think there is enough mountains on that map but it needs more hills. I have mine set to 0.65 and I still can get big areas of almost only hills but also some big areas of very flat land, which isn't that fun to build on. I would like hills to be more spread out and not in big clusters, if it's possible.
After lowering mconst.mountainsPercent to 0.90 the visible snow in warm regions disappeared but I don't want that loop that generates extra snow, since I can't really see the aesthetics in it. Can I delete that part? I have noticed that mountains can have snow on them in the middle of the map and that's what was causing the problem.
I can't make a screenshot of the whole map since I can't zoom out all the way in the game and I have no Worldbuilder installed.
That was a nice and thorough description with all the nails in place. I have looked at Communitas script and the landscape is to my liking except that it uses the africa tileset which I can't look at for long without feeling the urge to vomit. I hope there will be an option to change that in the future, or if I can change the whole tileset myself it would be all the better.
for y=0, elevationMap.height - 1 do
for x=0, elevationMap.width - 1 do
local plot = Map.GetPlot(x,y)
local i = elevationMap:GetIndex(x,y)
local artStyle = continentMap:GetAreaByID(continentMap.data[i]).artStyle
if plot:IsWater() then
plot:SetContinentArtType(contArt.OCEAN)
elseif jungleMatch(x,y) then
plot:SetContinentArtType(contArt.EUROPE)
else
plot:SetContinentArtType(contArt.[B]AFRICA[/B])
end
end
end
What the links for Communitas and World Builder? I don't see either in the workshop on steam.
I think there is enough mountains on that map but it needs more hills. I have mine set to 0.65 and I still can get big areas of almost only hills but also some big areas of very flat land, which isn't that fun to build on. I would like hills to be more spread out and not in big clusters, if it's possible.
After lowering mconst.mountainsPercent to 0.90 the visible snow in warm regions disappeared but I don't want that loop that generates extra snow, since I can't really see the aesthetics in it. Can I delete that part? I have noticed that mountains can have snow on them in the middle of the map and that's what was causing the problem.
I can't make a screenshot of the whole map since I can't zoom out all the way in the game and I have no Worldbuilder installed.
-------------------------------------------------------------------------------------------
--Landmass constants
-------------------------------------------------------------------------------------------
mconst.landPercent = 0.31 --Percent of land tiles on the map.
mconst.hillsPercent = 0.60 --Percent of dry land that is below the hill elevation deviance threshold.
mconst.mountainsPercent = 0.94 --Percent of dry land that is below the mountain elevation deviance threshold.
mconst.mountainWeight = 0.7 --Weight of the mountain elevation map versus the coastline elevation map.
--Adjusting these frequences will generate larger or smaller landmasses and features. Default frequencies for map of width 128.
mconst.twistMinFreq = 0.02 --Recommended range:[0.02 to 0.1] Lower values result in more blob-like landmasses, higher values make more stringy landmasses, even higher values results in lots and lots of islands.
mconst.twistMaxFreq = 0.055 --Recommended range:[0.03 to 0.3] Lower values result in Pangeas, higher values makes continental divisions and stringy features more likely, and very high values result in a lot of stringy continents and islands.
mconst.twistVar = 0.14 --Recommended range:[0.01 to 0.3] Determines the deviation range in elevation from one plot to another. Low values result in regular landmasses with few islands, higher values result in more islands and more variance on landmasses and coastlines.
mconst.mountainFreq = 0.4 --Recommended range:[0.1 to 0.8] Lower values make large, long, mountain ranges. Higher values make sporadic mountainous features.
--These attenuation factors lower the altitude of the map edges. This is currently used to prevent large continents in the uninhabitable polar regions.
mconst.northAttenuationFactor = 0.85
mconst.northAttenuationRange = 0.08 --percent of the map height.
mconst.southAttenuationFactor = 0.85
mconst.southAttenuationRange = 0.08 --percent of the map height.
--East/west attenuation is set to zero, but modded maps may have need for them.
mconst.eastAttenuationFactor = 0.0
mconst.eastAttenuationRange = 0.0 --percent of the map width.
mconst.westAttenuationFactor = 0.0
mconst.westAttenuationRange = 0.0 --percent of the map width.
-------------------------------------------------------------------------------------------
--Terrain type constants
-------------------------------------------------------------------------------------------
mconst.desertPercent = 0.27 --Percent of land that is below the desert rainfall threshold.
mconst.desertMinTemperature = 0.31 --Coldest absolute temperature allowed to be desert, plains if colder.
mconst.plainsPercent = 0.50 --Percent of land that is below the plains rainfall threshold.
mconst.tundraTemperature = 0.33 --Absolute temperature below which is tundra.
mconst.snowTemperature = 0.26 --Absolute temperature below which is snow.
-------------------------------------------------------------------------------------------
--Terrain feature constants
-------------------------------------------------------------------------------------------
mconst.zeroTreesPercent = 0.50 --Percent of land that is below the rainfall threshold where no trees can appear.
mconst.treesMinTemperature = 0.28 --Coldest absolute temperature where trees appear.
mconst.junglePercent = 0.88 --Percent of land below the jungle rainfall threshold.
mconst.jungleMinTemperature = 0.66 --Coldest absolute temperature allowed to be jungle, forest if colder.
mconst.riverPercent = 0.15 --percent of river junctions that are large enough to become rivers.
mconst.riverRainCheatFactor = 1.6 --This value is multiplied by each river step. Values greater than one favor watershed size. Values less than one favor actual rain amount.
mconst.minRiverSize = 24 --Helps to prevent a lot of really short rivers. Recommended values are 15 to 40. -Bobert13
mconst.minOceanSize = 5 --Fill in any lakes smaller than this. It looks bad to have large river systems flowing into a tiny lake.
mconst.marshPercent = 0.92 -- Percent of land below the jungle marsh rainfall threshold.
mconst.marshElevation = 0.07 --Percent of land below the lowlands marsh threshold.
mconst.OasisThreshold = 7 --Maximum food around a tile for it to be considered for an Oasis -Bobert13
mconst.atollNorthLatitudeLimit = 47 --Northern Atoll latitude limit.
mconst.atollSouthLatitudeLimit = -47 --Southern Atoll latitude limit.
mconst.atollMinDeepWaterNeighbors = 4 --Minimum nearby deeap water tiles for it to be considered for an Atoll.
mconst.iceNorthLatitudeLimit = 63 --Northern Ice latitude limit.
mconst.iceSouthLatitudeLimit = -63 --Southern Ice latitude limit.
-------------------------------------------------------------------------------------------
--Weather constants
-------------------------------------------------------------------------------------------
--Important latitude markers used for generating climate.
mconst.polarFrontLatitude = 65
mconst.tropicLatitudes = 23
mconst.horseLatitudes = 31
mconst.topLatitude = 70
mconst.bottomLatitude = -70
--These set the water temperature compression that creates the land/sea seasonal temperature differences that cause monsoon winds.
mconst.minWaterTemp = 0.10
mconst.maxWaterTemp = 0.50
--Strength of geostrophic climate generation versus monsoon climate generation.
mconst.geostrophicFactor = 3.0
mconst.geostrophicLateralWindStrength = 0.4
--Crazy rain tweaking variables. I wouldn't touch these if I were you.
mconst.minimumRainCost = 0.0001
mconst.upLiftExponent = 4
mconst.polarRainBoost = 0.00
mconst.pressureNorm = 0.90 --[1.0 = no normalization] Helps to prevent exaggerated Jungle/Marsh banding on the equator. -Bobert13
if radius > 7 then
radius = 7
end
for y = 0,self.height - 1,1 do
for x = 0, self.width - 1,1 do
local i = self:GetIndex(x,y)
dataCopy[i] = self:GetAverageInHex(x,y,radius)
end
end
[COLOR="SeaGreen"]local i = 0[/COLOR]
for y = 0,self.height - 1,1 do
for x = 0, self.width - 1,1 do
[COLOR="Red"]-- local i = self:GetIndex(x,y)[/COLOR]
dataCopy[i] = self:GetAverageInHex(x,y,radius)
[COLOR="SeaGreen"]i=i+1[/COLOR]
end
end
Sounds like you want to be changing the mconst.mountainFreq setting. Raising it will result in more sporadic placement of elevation features during map generation. I can't recall what the default setting is, but in my most recent WIP version, I have it way up at 0.4. You'll probably find this too sporadic if you like the looooong mountain chains and such. Here's a snippet of my re-organized main constants with concise comments (some of them may be constants I explicitly added to my version so you won't have those):
blablablabla
Is anybody still reading?
Well, 0.4 is a bit high for my taste but it surely spreads out the mountains a bit. I managed to get rid of the unwanted snow "bug" but I'm actually more interested in the communitas script since that one has more interesting landforms. Since you guys know your code, do you think you can find a way to get more luxuries on other islands than the one you start on in with that script(with the Terra option)? The problem is that the thread is not very well supported at the moment.