Get the latest tech news

Simulating water over terrain


If you don't want a long an boring introduction, skip directly to the virtual pipes method description. I will get a little bit sad if you do this, though x) I'm somewhat obsessed with terrain generation, grid-based games, simulations, and stuff like that.

Even those that do can often get away with some simplistic approach: I can easily imagine being able to fill up a hill in a game like Civilization (though it would probably break a lot of stuff gameplay-wise), and it doesn't interact with water in any way. The paper recommends using a factor of pow(friction,dt) to make it dt-independent (which is closely related to exponential smoothing I've explained in another article). If we look at Red Blob Games' amazing article on hexagonal grids, what I'm using is basically the axial coordinate system on a dual to a pointy-top hex orientation.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of terrain

terrain

Photo of Simulating Water

Simulating Water

Related news:

News photo

Show HN: 3D Terrain simulation for hiking, skiing etc.

News photo

Pathfinding to a moving target in evolving terrain

News photo

Robots can now walk through muddy and slippery terrain, thanks to moose-like feet