Decals in Unity


Unity is a pretty great engine and we love building games with it. But sometimes it has a few areas where it is still lacking the required functionality. A proper decal system is one of those cases.
Our terrain in BDF is pretty great looking and we do have good terrain textures and environment objects. However to make things really shine you need a layer of decals on top of the terrain to show things like dirt patches, cracks, blood, etc.

Decals on the Terrain

Decals on the Terrain

For example, in the above screenshot from our current build you can see a lot of decals. Some are easy to see, such as the blood patches,while others are harder to identify. There are subtle dirty areas around the towers and some custom cracks and patterns on the terrain. The fact that they are hard to see and blend nicely with the terrain actually means that they do their job well 🙂

Unity does not ship with a decal system and doesn’t offer any decent tech out of the box. There are a couple of plugins in the Asset Store which provide Decal functionality but none of those really matched what we needed in our type of game.
Usually we love middleware, plugins and any other way to reduce our workload. Time we don’t have to spend writing tools means more time spent on the game. But in this case we decided to build our own custom solution.
We are not quite done yet but we are on a good way with our own customs decal system for BDF. It is working pretty well so far and the first few level have been all ‘decaled up’.
If things go well we might put the decal system into the Asset Store for a low price so other teams can benefit from it. It needs a bit more testing and some optimization but we are pretty happy with it so far.

Check out a work-in-progress screenshot:

A decal mesh on the BDF terrain in a desert environment

A decal mesh on the BDF terrain

The scene in the sceenshot has a bunch ob rock assets placed on the terrain with decals covering up the borders.
It works on both meshes and terrain and does not require a collider on the objects. This is great and saves a lot of time during the level design phase, since designers can just slap on the decals where ever they want and not worry about collision proxies.

We’ll keep you updated once the system matures into something that can be actually shared in the Asset Store 🙂

Comments are closed.