Directional-Boring icon indicating copy to clipboard operation
Directional-Boring copied to clipboard

Using terrain layers to change the simulation behaviour

Open alin256 opened this issue 2 years ago • 6 comments

One cool idea for procedural terrain generation would be different geologic layers that affect the steering bias. So when you're in a "hard" layer, maybe it doesn't turn as sharply (and so on). It could be a color lookup like the collision detection.

Originally posted by @gradyh in https://github.com/CodingTrain/Directional-Boring/issues/2#issuecomment-1172479254

alin256 avatar Jul 10 '22 09:07 alin256

There are two things that I can think of that can be affected by the layers

  • [ ] When steering from a softer layer to a harder layer there is resistance to steering. Which can be on top or instead of current randomness.
  • [ ] When you calculate reflection response from the boulders the speed of sound in different layers is different. Ignoring the fact that there will reflection form any contrast we can account for time that sound-wave spends in each layer but use the constant of the top layer when estimating the seismic respnce.

alin256 avatar Jul 10 '22 10:07 alin256

Wait, so in that second bullet, are you talking about implementing seismic tomography? (Beyond just outlining the tops of the boulders.) I feel like that's way beyond the simplistic scope of the game... but is also totally awesome. You could even have a sensor deployment phase and a monitor; make it a whole mini game.

Djinn-Indigo avatar Jul 15 '22 12:07 Djinn-Indigo

It is already implemented (1st reflection) for the boulders.

How hard can it be?

Disclaimer: my seismic guy is on vacation, so I have no idea what I am doing.

alin256 avatar Jul 15 '22 12:07 alin256

I'm actually starting school for geophysics in a few months, so it probably wouldn't kill me to take a crack at it. I'll see what I can come up with in a few days. Disclaimer: I also have no idea what I'm doing.

Djinn-Indigo avatar Jul 15 '22 13:07 Djinn-Indigo

Keep me updated :)

alin256 avatar Jul 15 '22 15:07 alin256

@Djinn-Indigo, I have experimented with setting randomness constant to a different value depending on the dirt level.

Here is the code update FYI: https://github.com/alin256/Directional-Boring/commit/dcbaa6dc6a0866116189eadc0dffb3a4ea081867

alin256 avatar Aug 01 '22 08:08 alin256