Discussion
Loading...

Post

Log in
  • About
  • Code of conduct
  • Privacy
  • Users
  • Instances
  • About Bonfire
thomastc | frozenfractal
thomastc | frozenfractal
@thomastc@mastodon.gamedev.place  ·  activity timestamp 9 hours ago

Interaction between incoming waves and the coast. The effect is based purely on local depth. As the waves approach the shallows, they get shorter and taller, until a point where they suddenly lose a lot of amplitude.

If the wind blows away from the shore, though, this becomes a mess. I'll need to check the gradient of the distance to the coast and inhibit the effect.

#GameDev #IndieDev #IndieGame #GodotEngine #Godot #ProceduralGeneration #ProcGen

Your browser does not support the video tag.
GIF
GIF
Open
GIF
  • Copy link
  • Flag this post
  • Block
Joshua Barretto
Joshua Barretto
@jsbarretto@social.coop replied  ·  activity timestamp 7 hours ago

@thomastc Nice work! I think a solution probably looks like taking the dot product of the wind vector and the terrain gradient and using that to determine wave amplitude. Awesome stuff :)

  • Copy link
  • Flag this comment
  • Block
thomastc | frozenfractal
thomastc | frozenfractal
@thomastc@mastodon.gamedev.place replied  ·  activity timestamp 7 hours ago

@jsbarretto Yeah, that's the idea. The gradient needs to be smoothed, otherwise small underwater bumps will do weird things. The definition of "small" depends on wavelength though. Maybe something something mipmaps.

  • Copy link
  • Flag this comment
  • Block
Joshua Barretto
Joshua Barretto
@jsbarretto@social.coop replied  ·  activity timestamp 5 hours ago

@thomastc Ah, fair enough. Perhaps just sampling a handful of times over a wide area would be enough? The further apart the samples, the less effect any small discontinuities would have, and it's not like you really care to capture any significant detail

  • Copy link
  • Flag this comment
  • Block
thomastc | frozenfractal
thomastc | frozenfractal
@thomastc@mastodon.gamedev.place replied  ·  activity timestamp 5 hours ago

@jsbarretto So basically mipmaps 😉

  • Copy link
  • Flag this comment
  • Block

bonfire.cafe

A space for Bonfire maintainers and contributors to communicate

bonfire.cafe: About · Code of conduct · Privacy · Users · Instances
Bonfire social · 1.0.2-alpha.7 no JS en
Automatic federation enabled
Log in
  • Explore
  • About
  • Members
  • Code of Conduct