Page 1 of 1
Please add continents and islands elevation functions
Posted: Mon Sep 12, 2022 3:09 pm
by mrvn
TL;DR
Make the 0_17-islands+continents elevation function available in the GUI and add a new islands elevation function.
What ?
The game already defines an 0_17-islands+continents elevation function but the game does not offer that function as elevation function for the terrain in the GUI. Adding this elevation function produces maps like these (scales of 1, 4, 16 and 64):

- continents1.png (80.57 KiB) Viewed 3607 times

- continents4.png (89.71 KiB) Viewed 3607 times

- continents16.png (105.69 KiB) Viewed 3607 times

- continents64.png (175.89 KiB) Viewed 3607 times
They do look nice and playable so why isn't this elevation function available as terrain elevation in vanilla?
Personally though I think the continents are too big for me. Even being wasteful you probably only need to get to 1 continent to finish the rocket. So I came up with an alternate elevation function that produces smaller islands by inverting the normal elevation. Land becomes water, water becomes land. Except the starting points are preserved and then faded into the inverted elevation to give a starting island. (scales of 1, 4, 16 and 64):

- islands1.png (54.35 KiB) Viewed 3607 times

- islands4.png (67.03 KiB) Viewed 3607 times

- islands16.png (120.17 KiB) Viewed 3607 times

- islands64.png (179.13 KiB) Viewed 3607 times
This could be easily added to the game too:
Code: Select all
local dist = noise.min(1.0, noise.max(0.0, noise.var("distance") - noise.var("starting_area_radius") / 4) / noise.var("starting_area_radius"))
local elevation = noise.delimit_procedure(noise.var("0_17-lakes-elevation"))
data:extend{
{
type = "noise-expression",
name = "inverse-" .. name,
intended_property = "elevation",
expression = noise.clamp(elevation + tne(1), 0, 1) - dist - dist * elevation
}
}
Why ?
Different styles of maps are fun to play with and for mods that add
boats or air travel the default and island generators aren't making the best use of the new modes of transportation. Even without using landfill to hop from island to island can be fun.
You can play with the amount of water to get islands on the default terrain but that is huge continents with barely any water between them. There is no challenge to landfill a bridge between them. A boat line to transport items might no even fit in the channel due to the turning radius of rails. Nothing like wast oceans with islands sprinkled in them like these elevation functions produce.
So I think these new styles of map would add something new and interesting to the game. One is already in vanilla and just need to be made available in the GUI. The other is so small it would be trivial to add too.
Re: Please add continents and islands elevation functions
Posted: Tue Sep 13, 2022 6:58 am
by ssilk
What I understood was this: there is some parameter in the map generator, which does something, and you want to have it available in the GUI of the map-generator. And you also suggest to add another parameter which depends somehow to a distance and reverses that first parameter.
The rest I don’t understand. Especially the pictures are very irritating, because I don’t see anything on them. Maybe it’s, because I don’t know what I should look for. Maybe it’s me, because I’m sometimes take some while longer to understand a new concept. So if you would be so kind to explain your idea in other words?
Re: Please add continents and islands elevation functions
Posted: Tue Sep 13, 2022 9:46 am
by mrvn
The images are each 16 randomly generated maps created with
Code: Select all
bin/x64/factorio --generate-map-preview islands.png --map-preview-scale X --map-preview-size 256
where X is 1, 4, 16, 64 just to give preview of how the generate maps look like.
For the first set there is a evelation function defined in
data/core/prototypes/noise-programs.lua called "0_17-islands+continents". But the noise-expression is added to
data using
Code: Select all
{
type = "noise-expression",
name = "0_17-islands+continents",
intended_property = debug_property("elevation"),
--Similar to lakes, but with a negative bias instead of a positive one
expression = noise.define_noise_function( function(x,y,tile,map)
x = x * map.segmentation_multiplier + 10000 -- Move the point where 'fractal similarity' is obvious off into the boonies
y = y * map.segmentation_multiplier
options =
{
bias = -80,
terrain_octaves = 10
}
return finish_elevation(make_0_12like_lakes(x, y, tile, map, options), map)
end)
},
If
Code: Select all
intended_property = debug_property("elevation"),
is changed to
then the noise-expression would be available in the map generator as terrain elevation.
The second part defines a new noise-expression that would also have to be added to
data that uses the normal "0_17-lakes-elevation" and turns every lake into land and all land into water. Except for a small region in the starting area. The complex looking formula is there so the transition from the starting area to the inverted region isn't jarring.
Re: Please add continents and islands elevation functions
Posted: Tue Sep 13, 2022 6:23 pm
by ssilk
Thanks. I realized that I missed to read the "WHY", because of the pics, so this makes now sense.
Perhaps next time you can hide the pics with a spoiler:
Code: Select all
[spoiler=Naked pics]
[img][/img]
[/spoiler]
Re: Please add continents and islands elevation functions
Posted: Sun Oct 09, 2022 11:52 am
by Dmytrozern
Not sure I would use this gen, since I don't use air/water mods, but I'm down for having a more diverse gen!
Re: Please add continents and islands elevation functions
Posted: Mon Oct 17, 2022 8:36 am
by stann_co
I don't use any air water mods. But i think i would like to try. Using maps like these! Having sea play a bigger part, and transporting goods through either
boats, or by constructing long bridges sounds like a fun concept. I might make a seperate post detailing this

Re: Please add continents and islands elevation functions
Posted: Mon Oct 09, 2023 11:09 pm
by Nyrrix
I think this suggestion makes a lot more sense with the onset of the expansion. The generator, even in mods like Space Exploration, produce unvaried terrain. With new planets, more varied terrain variables can spice up the gameplay on each planet.
And for the question of making the variables adjustable in the world generation settings: this would be a valuable addition when accounting for the new elevated rail system being added. The elevated rails essentially provide an "official" way to cross water, so you could conceivably play with no landfill (or landfill turned off as an extra challenge). Creating a multi-island world and playing with elevated rails would really provide an entirely new experience.
Re: Please add continents and islands elevation functions
Posted: Tue Oct 10, 2023 3:42 am
by FuryoftheStars
+1 Yeah, I'd love to see more variety in map generation.
