Anyway to stop spawning islands on Pangaea?

spfun

King
Joined
Oct 8, 2010
Messages
655
I just want 1 big landmass, is it possible to tweak XML somewhere for this? ta
 
I just want 1 big landmass, is it possible to tweak XML somewhere for this? ta

No.

The map scripts are purely Lua files, which means they're not nearly as easy to modify, and they're not even COMPLETE Lua in that they tie into stubs in MapGenerator.lua and AssignStartingPlots.lua, so you'll have to go back and forth to make sure your changes are solid. Effectively, they ARE mods, because some of them override routines in the core Lua with altered versions. There's also a weird order-of-operations thing going on; if my mod modifies AssignStartingPlots.lua, and the map script also modifies AssignStartingPlots.lua, the map's version takes precedence. So you definitely can't mod the map script through some second mod.

If you know what you're doing with Lua modification then it wouldn't be too hard to do what you're asking, but it's not something that can be included as a mod; you'd basically have to create a new map script (Pangaea_Mine or something), run that instead of the normal one, and hope that you didn't leave out anything important.
 
thanks for the reply

I don't really know to much about modding unfortunately. I don't want to make a mod I really just want Pangaea maps to stop spawning 1 tile islands because the AI have no clue how to take them over. You say its easy to do this? I'd like to know how!

Thanks
 
Fine, but maps ARE mods, and if you're bad at modding then it's not going to be easy to get what you really want. Here's what happens.

The Pangaea map script doesn't actually create a single continent. What it does is creates a randomized "mountain", with each hex getting a value between 0 and 100, and picks a certain height to be sea level. Anything below that height is set to ocean, anything above that height is set to land (and Hills/Mountains are set based on how far above this sea level it is). So those single islands you're seeing are really sort of like secondary peaks on the "mountain".
Actually, that's how all fractal map scripts work. The unique part of the Pangaea script is that it'll start over again if the largest landmass has less than 84% of the total land. It repeats the process until it gets one that works, and if you run FireTuner you'll see it often trying hundreds of maps before it succeeds.

So there are basically two things you could do in a copy of Pangaea.lua:
1> Change the rejection threshold to something higher, like 90%. If you set it to 100%, though, it'll never finish, because the fractal algorithm has enough randomness in it that you'd always get SOME small islands. Even 90% might be a problem, but you'd have to try it to find out.
(Go into the Pangaea script and search for "0.84". It's easy to find.)

2> Smooth the fractal curve, to make less variation, by adjusting the "grain" values. Unfortunately, this'd probably make the continent look perfectly round with all the mountains in the middle, which'd be bad.
In the file, it sets grain_dice and rift_dice, which are used as inputs to the fractal algorithm (FractalWorld:InitFractal). It looks like rift_dice is the one you want; the Pangaea map allows this to be -1, 1, or 2. The negative value seems to be the one you want, since it looks like this controls whether the game creates a gap between two continents. So change the map script to always put this to -1, and see what happens.

So open ModBuddy. Make a new map script. Go into your Maps directory (for me, that was C:\Program Files\Steam\steamapps\common\sid meier's civilization v\assets\Maps\), open up Pangaea.lua, copy everything in it into your new script, and then edit those few lines. Save it as some new name (MyPangaea.lua or something), and you should be ready to go.
 
Back
Top Bottom