When we entered the production stage of HYPERNOVA: Escape from Hadea, there was a number of things to do. Among them was creating a new kind of terrain. With the information we had, we had to define a couple of rules or rather, design principles, both from the gameplay and visual standpoint. What kind of planet do we have? Are we aiming for an Earth-like setting or something more alien-ish? How is the terrain constructed? How large should it be? How does it affect the gameplay?
From a gameplay perspective, this game is partly a tower defense game, so we wanted the terrain to reflect this. We decided it should be split into two parts – roads and sectors. The roads have a similar role to the classic tower defense games (TD) - the enemies use them to move quickly about. The sectors, on the other hand, are flat pieces of land to place buildings and towers.
Next: how large should the terrain be? Instead of classic system with separate levels, we decided to implement a single sandbox/open world style map . This means the player spends the entire game on the same map. With this in mind, we decided to do a couple of things.
First, the map needs to be larger than usual TD or RTS game's map. After a couple of tests, we decided to have a 3 km by 3 km terrain size. This allows you to play and finish the game without being constrained by the size of the level. If an area is particularly difficult, there is a possibility to expand into another direction.
Since there is only one map, we wanted to avoid being too repetitive. We did this by adding different environments. We played around with various ideas, like different rocks, plants and such. Eventually, we decided to add a couple of large, unique areas to each part of the landscape. They would not only look different, but also affect the gameplay.
For example, one area is volcanic. It has a volcano in middle, with barely any plants. Mostly there are rocks, lava flows and similar elements. The volcano in the middle is active, meaning it can expunge hot magma »rocks«. These are able to hit the player’s buildings and damage them. On the other hand, the resources in this area are more abundant. Another area is desert-like. Lots of space to build on but few natural obstacles, meaning it is harder to defend. The player can always make a decision where to start. This increases the replayability of the game.
We ended up with nine different areas, each one with its own unique elements. We created plants, rocks and other assets for each of these, as well as some unique terrain textures.
Terrain texturing was also something we had to think about. The default Unity terrain is slightly limited in this aspect. The interaction between texture layers cannot be controlled properly and it doesn't feature height map blending. Not cool. After some research work, we decided to use custom terrain shaders. These allowed us to do many advanced things, like normal/height map blending, usage with up to 12 textures, parallax mapping, global color map etc.
Next, we had to play around with colors. We didn't want to have Earth-like colors, but still didn't want to go completely alien either. We tried to play with different color palettes and we had some problems to solve. We had to take into account several factors: roads, sectors, enemies, buildings, towers... All had to be clearly visible. Balancing out two or three things is easy to handle, but with so many different factors, it was tough to choose the right color scheme. Eventually we went with blue tones for sectors and warm colors for roads.
Another thing regarding gameplay. We wanted player to be sure that he or she knows exactly where the enemies are able to pass from a road to a sector and where they are not. To achieve that, we used a special texture clearly marking the corridor. We used the road sand texture with some smaller blue rocks from the sector at the places where there were small cliffs so that the enemy can still pass. On the other hand, at the places where the enemy couldn’t pass, we used a dark blue texture to make a clear difference. This was strictly gameplay related, but it does help a lot.
All in all, the terrain process looked like this. Firstly, we created a terrain mesh from a height map, then sculpted it with default Unity tools, with sectors and roads in mind. To add variety, we raised some areas around the roads so the sector couldn't be reached from anywhere. After that, we used a special plugin (RTP) to paint textures onto the terrain. They were created using photo manipulation in Photoshop, adding some manual overpaint. Finally, we created sets of assets/prefabs, like vegetation, rocks and similar, and placed them around the terrain to enliven to the newly created world.
One last important thing to consider was the performance. We had lots of rocks, trees and grass, and some parts of the rocky formations were partly inside/below the terrain. That means we had to render lots of wasted polygons. Our programmers created some scripts to remove these polygons and combine rocks (and plants) into larger batches. In this manner, the poly and batch count was reduced significantly. This improved the rendering performance a lot, by 30%. However, in the final build, we used mesh instancing and increased the performance by 40%.
A part of the terrain finalized... Purple forest.
As always... the end result (near the Vulcano area).
We learned a lot doing this feature, technology-wise and and from the game design point of view. The color scheme was a big challenge, and maybe we could have pulled it off a little better, but it was a fun experience.
That's it for now. Thanks for reading, cheers!