Realistic Terrain Generation

Realistic Terrain Generation

3M Downloads

River bank surfaces

whichonespink44 opened this issue ยท 15 comments

commented

@Zeno410 @KdotJPG @topisani @VelocityRa

Calling all noise experts!! (Velocity, I'm not sure if you're a noise expert, but I once heard you mention something about noise that I didn't understand, so that qualifies you in my book! ๐Ÿ˜› )

Right, so basically with all the changes to terrain, rivers, and decorations recently, the surfaces of river banks in hot biomes aren't getting painted the way they used to. Previously, the banks of rivers in hot biomes were painted with lush grass and biota all along the edge of the river, and it looked pretty cool. But that's not happening anymore.

Here's what it used to look like:

Vanilla Desert Hills

And here's what it looks like now:

2016-04-11_07 42 33

As you can see, it's still getting painted - it's just a lot more 'broken up'.

I'm 99.999 (repeating of course) % certain that this is the line we need to tweak in SurfaceRiverOasis:

https://github.com/Team-RTG/Realistic-Terrain-Generation/blob/dev/src/main/java/rtg/world/gen/surface/SurfaceRiverOasis.java#L24

I've already tried all sorts of different combinations of values, but I can't get anything that looks better than what we have already.

Any chance one of you guys could come up with a better formula?

I don't think we need to get it exactly as it was before, but if we could at least make it a little less broken up along the edges, I think that would be a great improvement.

commented

Doesn't just decrementing the threshold (the > 0.8f to 0.7f or something) make the grass "expand"?

commented

The times I managed to make it expand along the edge of the river, it expanded too far away from the river into the desert. I thought I'd tried changing each of the different components of the formula, but I couldn't find a combination that seemed to work.

commented

I'm guessing the reason is that the changes I've made result in very little "river" valued terrain not actually being "river". I think VelocityRa has it right, it's just that small differences in thresholds can have a big effect.

Without looking at it, I'd have thought the relevant code would actually be in SurfaceDesert or whatever.

commented

Getting closer I think? Still need to make the rivers squiggly like in the 1st pic (which I don't know how to do)
Edited my comment because of Topi's remark below
2016-04-12_00 07 49

commented

thats not overridden, just old squiggilier rivers i think

commented

The squiggles from the first pic are optional, unless you guys prefer them? I'd just be happy if more of the edge (where the water meets the land) was grass.

Actually, Zeno's probably right about SurfaceVanillaDesert needing to be involved with this as well. This section of code in particular might need to be tweaked to match (counter-match?) the changes that are made in the SurfaceRiverOasis:

https://github.com/Team-RTG/Realistic-Terrain-Generation/blob/master/src/main/java/rtg/world/gen/surface/vanilla/SurfaceVanillaDesert.java#L29

commented

It's pretty much same code though from what I can see, doesn't matter where it's run all that much.
Also: I would indeed like them a bit more squiggly Pink.
Progress (maybe I should involve height in there as well so grass doesn't appear so high):

2016-04-12_00 49 40

Thoughts?

commented

definately agree with velocity on the squiggilies, but i also think you should add a few more octaves to the noise. It still looks very mathmatical. Also, someone with decorations knowledge should turn up the frequency of those acacia trees closer to the river

commented

I may know someone who can help in that area ๐Ÿ˜

All those suggestions sound good: height restriction (can it go by distance from river as well, so like only noiseX blocks from the edge? not all river banks go up the side of a cliff) and squiggles are cool with me.

commented

I've put a lot of effort into "de-squiggling" the rivers. I never liked that and it makes navigation problematic. I'd prefer than the "river biome" not go so far from the river. I think the grass areas are noisy enough as is, although a noisy height cap would add a little more variation.

The reason the rivers aren't squiggly is that in the two-step process (flatten the land and then place the river) I did some simple transforms so the middle of the river is flat at 0 or 1 (depending; it's actually -1,0 in some places and 0,1 in others). The flat area is basically where the river shows up.

commented

Tossing this out : it would be interesting if the cutoffs varied on a large scale so some rivers were barren and some lush.

commented

Maybe a config to enable/disable squiggly rivers would make everyone happy?

commented

Yeah, I suppose they don't always have to be lush.

Just for clarity Zeno, you're referring to the 'squiggliness' of the surface painting, and not the squiggliness of the shape of the river terrain, right?

commented

I was talking about both, but the squiggliness I removed was in the terrain shape. The changes to the grassy areas on the sides were unintentional. I do think having blobs of grass surrounded by sand or vice versa is dubious, although I know it's hard to prevent with our noises.

commented

Added in #630