August 6, 2015 by Daniel
Our regular readers might have a feeling of deja-vu, but there’s one big difference. Let me expand.
Our development blog post no. 5 explained how procedurally generated terrain works. We showed you how changing numerous variables changes the appearance of the planet and it’s topographic qualities. We were thrilled by the possibilities. That is until we realized the 3rd party voxel engine we decided to use was in no shape to provide the performance we’re aiming for in Planet Nomads. So in the very next dev post (no. 6) we commited to creating our own voxel-based procedural terrain engine that could do the same wonders, but with much higher FPS and loading speeds. Girls and boys, our lovely Nomads, we’re much closer to that goal now.
Let’s Make Some Noise
The different mountains and valleys, every fold and crease and cave and hill, they are all generated by the so-called noise generators. Each generator has different effect on the terrain and by combining different generators into nodes you can create virtually any type of terrain. All with the simple use of not so simple maths. It’s magic. Also a long run of try and error with sometimes unexpected results, but magic nonetheless.
Right now Martin has integrated these nodes into our engine and they are starting to work in a very promising way.
Grass. Good Looking, Dense and Powerful Grass, Waving in the Wind
Grass was a long-time nightmare for Tomáš. The first attempts took a lot of the available computing power to look any good. When he tried to tune the complexity down, the grass looked like a lame try of a first time wannabe gardener. It was shameful. We won’t lie to you, Nomads, desperation fell upon us. At one point we nearly opted for 2D sprites that ‘looked OK’. Shame on us!
This story has a good ending though. Very good. Tomáš won his fight in the end and created a grass system that runs with solid 60 FPS on a measly Radeon HD 6770M. Stellar performance, great achievement. With the grass sorted out, Tomáš is now moving on to conquer water, one of the most elusive elements. He’ll either end up victorious or die trying. We’ll let you know.
So to sum it up, we had to invest precious time to code our own voxel-based terrain engine, but the gains far outweigh the costs. It’s already showing in performance, but the benefits will mainly show in the long-run, months and years after Planet Nomads, our sandbox game with procedurally generated planets, has been released. We’ll end up with the ability to scale Planet Nomads with ease, to enable all the features we have in store, fast multiplayer, vast planets and building of massive vehicles, structures and in the end, spaceships.
-Who said maths wasn’t fun? Juggle with the numbers and worlds come to life!
-If only you could see the weed in motion.