Friday Facts #207 - Lua noise specification

Regular reports on Factorio development.
orzelek
Smart Inserter
Smart Inserter
Posts: 3923
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by orzelek »

Wow nice terrain :)

And noise functions in lua - seems like something new to play with on 0.16 release.
Will those also work for ores/biters?
User avatar
ZombieMooose
Filter Inserter
Filter Inserter
Posts: 289
Joined: Mon Feb 09, 2015 7:23 am
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by ZombieMooose »

Islands are the best starting zones. People actively look for exchange strings with island starting locations.

I don't like this potential change at all.

I do like the terrain features tough. They look like they could be potentially varied especially if they're moddable and people can add more.
"men will literally learn everything about ancient Rome instead of going to therapy"
IronCartographer
Filter Inserter
Filter Inserter
Posts: 464
Joined: Tue Jun 28, 2016 2:07 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by IronCartographer »

diongham wrote:Islands are the best starting zones. People actively look for exchange strings with island starting locations.
The 0.13-era mapgen and its tendency to create island starts with perfect resource availability is good, but hasn't quite eliminated the impossible island starts with a handful of tiles under the player in what's supposed to be your guaranteed source of boiler water.

Eliminating the issue would only require a very small filter effect...or a recipe for a cheap boat which you can make with your initial scrap metal. ;)

Edit: The "It stinks and they don't like it" achievement would also benefit from requiring that biters are able to find a path. I've seen it trigger when they were actually unable to reach the pollution source, even though it wasn't an island (extremely large peninsula).
Last edited by IronCartographer on Fri Sep 08, 2017 6:19 pm, edited 1 time in total.
TOGoS
Former Staff
Former Staff
Posts: 97
Joined: Fri Jun 24, 2016 2:29 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by TOGoS »

diongham wrote:Islands are the best starting zones. People actively look for exchange strings with island starting locations.

I don't like this potential change at all.

I do like the terrain features tough. They look like they could be potentially varied especially if they're moddable and people can add more.
You'll still be able to get islands by setting water level to [very] high or using an alternate elevation function (either an alternate built-in one for just this purpose, or one provided by a mod)
orzelek wrote:Will those also work for ores/biters?
Noise for elevation/humidity/temperature is handled a little bit differently than one-off noise layers for entity placement, e.g. for biters. In theory it shouldn't be too difficult to unify the two system (which would also have the advantage that we could delete a bit of code), but right now the focus is on making a good default terrain, so that probably won't happen for 0.16. Mods can still alter placement using the (somewhat obscure) peak system though.
orzelek
Smart Inserter
Smart Inserter
Posts: 3923
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by orzelek »

TOGoS wrote:...
orzelek wrote:Will those also work for ores/biters?
Noise for elevation/humidity/temperature is handled a little bit differently than one-off noise layers for entity placement, e.g. for biters. In theory it shouldn't be too difficult to unify the two system (which would also have the advantage that we could delete a bit of code), but right now the focus is on making a good default terrain, so that probably won't happen for 0.16. Mods can still alter placement using the (somewhat obscure) peak system though.
I was interested due to RSO mod - with custom noise layers it could switch to those for ore generation.
TOGoS
Former Staff
Former Staff
Posts: 97
Joined: Fri Jun 24, 2016 2:29 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by TOGoS »

orzelek wrote:I was interested due to RSO mod - with custom noise layers it could switch to those for ore generation.
I haven't inspected the source, but I'm guessing RSO works by placing entities explicitly from an on-chunk-load callback. That will always be the method that gives mods the most flexibility, but for things like elevation that need to be calculated for every single tile, it might not be too great performance-wise.
Zavian
Smart Inserter
Smart Inserter
Posts: 1649
Joined: Thu Mar 02, 2017 2:57 am
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Zavian »

I look at the 'web' in the second picture and think yuk. That looks so artificial. Personally I don't think that the you need the starting area to be connected to the rest of the map provided it typically contains some biter bases and enough stone for your initial base + walls + landfill.

Have you considered making the starting area some sort of peak or hill that encompasses the entire starting area and its resources , plus has a few nearby biter bases, and then adding a few small lakes for power generation/refineries 2-3 chunks from the spawn point ?

If a single hill looks to regular, then add an additional 4-12 hills each with random heights and slopes, each offset randomly around 4-8 chunks from the spawn point.
Omarflyjoemacky
Fast Inserter
Fast Inserter
Posts: 104
Joined: Tue Nov 15, 2016 10:56 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Omarflyjoemacky »

Looking at this generated map - does this mean we will end up with elevated terrain? Very exciting if so. Hill, mountains, valleys!! :)
"And then Bender ran."
User avatar
Proxy
Fast Inserter
Fast Inserter
Posts: 165
Joined: Mon Mar 30, 2015 11:10 am
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Proxy »

man, can't wait to see the new Terrain in action.

Giant Lakes and Oceans would not be a problem if we had Cargo Ships *wink* *wink*
Omarflyjoemacky
Fast Inserter
Fast Inserter
Posts: 104
Joined: Tue Nov 15, 2016 10:56 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Omarflyjoemacky »

Proxy wrote:man, can't wait to see the new Terrain in action.

Giant Lakes and Oceans would not be a problem if we had Cargo Ships *wink* *wink*
Please yes!! And Cargo Planes! Can you see it? Cargo ports and air terminals loading onto trains?!
"And then Bender ran."
IronCartographer
Filter Inserter
Filter Inserter
Posts: 464
Joined: Tue Jun 28, 2016 2:07 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by IronCartographer »

TOGoS wrote:
orzelek wrote:I was interested due to RSO mod - with custom noise layers it could switch to those for ore generation.
I haven't inspected the source, but I'm guessing RSO works by placing entities explicitly from an on-chunk-load callback. That will always be the method that gives mods the most flexibility, but for things like elevation that need to be calculated for every single tile, it might not be too great performance-wise.
That's true, but people still use it because the vanilla resource generation doesn't raise the threshold for resources appearing when the frequency is decreased. This leads to annoying small patches scattered between the desired, larger ones--especially when size is increased at the same time.

If you're ever working on the resource distribution in vanilla, and you can find a way for the "frequency" setting to also re-scale the waveforms with some nonlinearity in addition to simply decreasing the raw frequency (creating truly isolated, large resource nodes)...That would replace RSO at long last. ;)

If the frequency could somehow get lower and lower as distance from spawn increases, that might be interesting too.
miturion
Long Handed Inserter
Long Handed Inserter
Posts: 79
Joined: Mon Aug 03, 2015 5:46 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by miturion »

Omarflyjoemacky wrote:Looking at this generated map - does this mean we will end up with elevated terrain? Very exciting if so. Hill, mountains, valleys!! :)
I think you should read it again. It is not to have elevated terrain in the game, just to show how terrain is generated.
Omarflyjoemacky
Fast Inserter
Fast Inserter
Posts: 104
Joined: Tue Nov 15, 2016 10:56 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Omarflyjoemacky »

miturion wrote:
Omarflyjoemacky wrote:Looking at this generated map - does this mean we will end up with elevated terrain? Very exciting if so. Hill, mountains, valleys!! :)
I think you should read it again. It is not to have elevated terrain in the game, just to show how terrain is generated.
I see it now. "added height shading". Sigh. Balloon deflated. That's what happens when you scroll down quickly to the bottom to see the next high res upgrade and immediately see that map instead.

Factorio 2 I suppose. :roll:
"And then Bender ran."
bluerock
Inserter
Inserter
Posts: 28
Joined: Fri Sep 08, 2017 7:11 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by bluerock »

Regarding solving the issue with starting on an island... I agree that starting on starting on an island can be fun, but that we just want to avoid starting on an island that is TOO small without sufficient resources. It seems to me that a relatively easy way to resolve would be to use something like a 4-way flood fill algorithm starting at the player start location and use it to count land tiles surrounding the player above sea level. Maybe allow the player to set the value. For example a value of 40,000 would mean that the algorithm would check to be sure that the player isn't starting on an island smaller than about 200 x 200 in size (if the island happened to be squarish). I don't really like the thought of adding in a webbing or some other structure on top to deal with islands as I am not sure it can be done without looking like a 'patch' that doesn't really fit with the rest of the terrain generation.
IronCartographer
Filter Inserter
Filter Inserter
Posts: 464
Joined: Tue Jun 28, 2016 2:07 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by IronCartographer »

bluerock wrote:I am not sure it can be done without looking like a 'patch' that doesn't really fit with the rest of the terrain generation.
Kind of surprising that's not how it works, actually. Generating the starting area with its own dedicated system with a randomly blurred/blended biome edge would allow players to choose their preferred biome start, then have it merge with the rest of the world naturally. :)
pleegwat
Filter Inserter
Filter Inserter
Posts: 278
Joined: Fri May 19, 2017 7:31 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by pleegwat »

bluerock wrote:It seems to me that a relatively easy way to resolve would be to use something like a 4-way flood fill algorithm starting at the player start location and use it to count land tiles surrounding the player above sea level. Maybe allow the player to set the value. For example a value of 40,000 would mean that the algorithm would check to be sure that the player isn't starting on an island smaller than about 200 x 200 in size (if the island happened to be squarish).
I think there's some merit in this idea - to avoid starting on a tiny island, rather than changing the map generation to make it impossible, you make it so if it does happen you can detect it and simply discard that seed.

Of course, you still want to reduce the chance these situations pop up or your world generation could get very slow.
MrGoodbits
Inserter
Inserter
Posts: 25
Joined: Mon Jun 27, 2016 9:33 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by MrGoodbits »

I don't care what size a tiny island might be, as long as I have resources to be able to build enough to get off the island. So perhaps a flood fill to find land and resources to verify you can at least get to landfill researched. If not, then either re-seed or add the bridges.
User avatar
Durabys
Fast Inserter
Fast Inserter
Posts: 236
Joined: Mon Apr 18, 2016 3:30 pm
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Durabys »

What are those purple ore field splotches in the second map? Oil? Did you change how oil is going to be extracted?
Jap2.0
Smart Inserter
Smart Inserter
Posts: 2375
Joined: Tue Jun 20, 2017 12:02 am
Contact:

Re: Friday Facts #207 - Lua noise specification

Post by Jap2.0 »

I am also against the idea of the spiderweb thing near your start. It could mess up early-game defense - now, with a good starting area you can get away with only defending 3 sides of your base, with a lake on one side - or only defend one side if you find a nice peninsula. With these changes, there would be many paths through the water you would have to block off as well. These is also the fun challenge of getting off an island. My suggestion would be to try to path to a dozen points a few hundred or thousand tiles away (or use some other algorithm to find if you are on an island), and then if at least, say, 10 fail, look to see if enough resources to easily research landfill and make a generous amount are available. If not, generate a new map. Alternatively, in the advanced options, you could put an option to turn this off or set the threshold for the minimum amount of resources on the island.
There are 10 types of people: those who get this joke and those who don't.
Post Reply

Return to “News”