-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Physics based water system. #11
Comments
So you'd want the rivers to change at runtime? Because that will probably not happen. It's possible I might add the ability to have rivers be placed in the editor based on the terrain height. |
Well, not just Rivers, but Water flowing from upper gradient to lower gradient. |
Probably won't happen. The calculations needed to make the mesh and the flowmaps is not something you could calculate every frame for a dynamic system. Waves when the player enters the water will probably happen. I'll leave this open for now for any further discussion of the subject and we can revisit the discussion when I've finished the big rewrite of waterways I'm working on to make branching rivers and lakes possible. |
It appears you are requesting a realtime fluid simulation which is not only extremely difficult, it would be so cpu intensive as to leave little bandwidth for your actual game. This repository is also the wrong tool for this request. This tool creates a spline plane mesh with a realistic water shader on top of it. And it's really good at doing that. It is on par with the equivalent UE4 tool (pre 4.26). Fluid simulation is incredibly impractical. I'm using this tool for a river, a lake and now a waterfall in a 3D ARPG on HTerrain. You don't need accurate physics. You need creativity and experimentation. If you need accurate fluid simulation, create it in blender and bake the animation. You'll have accurate physics, but incredibly high resolution meshes and animations. |
Well, I'm making a City Building game which allows for terrain changes, I'd love to have the water go up if the terrain above it changes, I'll take a look into Cities: Skylines again. |
it can be approximated with floodfill algorithm as stated by @Arnklit.
The problem is, my game is dynamic, it's not static and I wouldn't be able to just use animations. But yep, the floodfill algorithm would be really helpful. |
Yeah I'll leave this open for now. I think if I make a dynamic water system it will possibly be a separate asset. This video @sairam4123 sent me shows the idea well. https://www.youtube.com/watch?v=rW8YZRtmTgo As far as I can tell this should all be possible by using a high density water plane that gets displaced based on something like a floodfill algorithm that also takes terrain height into account to decide how the fill happens and uses the movement of the fill to drive the flowmap generation. One of the problems with this is that it would be very interconnected with the terrain system and since Godot doesn't currently have a built-in terrain system, this kind of water system would have to be built around one of the terrain plugins. |
Is your feature request related to a problem? Please describe.
The current waterways is static. I would love to see a dynamic water system.
Describe the solution you'd like
A dynamic water system which flows from WaterSpawner to Ocean.
Uses the heights of the HTerrain to flow from Mountain to Sea Level.
The text was updated successfully, but these errors were encountered: