If you go for Unity and Biomes, as you wrote in your article, please do support Vegetation Studio Pro. Your work is awesome, can't wait to see it on the store.
Great breakdown of the process and optimization, thanks for sharing.
This article just not only provides great tools for level design. It's also useful vocabulary to express ideas with our team. https://xbeasts.blogspot.com/2018/12/Remove-Wall-Decals.html
Senior Technical Artist Magnus Larsson talked about the way he sets up incredible destruction simulations in Houdini and exports them to UE4.
Types of Destructions in Game
I would say that there are 2 types of destruction: Real-Time destruction which often is handled by systems like Havok or Apex, and Pre-Baked simulations that you author outside your game engine with 3D Software like Houdini which I use.
Working on Rigid Bodies
Of course, there are many ways to do this, but I create Rigid Bodies in Houdini, both for Real-Time use and for Pre-Baked simulations.
Most of the time I use the Voronoi Fracture node as a base. But there are many ways today to modify things to get better results:
- A very basic thing is to cluster Voronoi pieces together to get more interesting shapes.
- Use the Rest position trick where you deform the incoming mesh with noise before your fracture it with the Voronoi Fracture.
- For wood fracturing you can scale things up in 2 axis before applying Voronoi Fracture and then scale those 2 axis back down again, that will make it look more like broken wood.
- You can also use the new Boolean SOP in Houdini for more advanced tricks in combination with the Voronoi it can make great looking fractures.
And in Houdini, it’s rather easy to keep track of the pieces. If you use Voronoi Fracture straight up it has already taken care of it for you while if you use a more custom approach you can put down a “assemble” SOP node in the end.
When it comes to the way simulation works in a game, the first thing to understand here is that it both might and might not always be unique. For example, after shooting columns can crack all the same way or a bit differently. It’s a choice that the game creators have to make depending on what they like, how they want the game to look, what they focus on and what they are willing to spend performance on.
Real-Time physics can have great impact on your game performance and sometimes even create game breaking things.
Pre-Baked simulations will look the same every time, and be more dependable because the result is known in advance, but of course, less fun to shoot at.
You can also make variations of the Pre-Baked simulation. An example of that would be a pillar that might have 4 different simulations depending on which direction it is hit from.
Another benefit of using Pre-Baked simulations is that you can use advanced setups with directable constraints to make much cooler looking simulations than you would ever get in Real-Time, at least where we are today with technology.
A good balance usually is to have greater epic things as Pre-Baked simulations while smaller things you can interact with (shoot at) to be Real-Time.
Another big difference is if you Pre-Fracture things or Fracture things in Real-Time, – just as with Pre-Baked simulation vs Real-Time, – you get more control and quite possibly better-looking pieces if you Pre-Fracture things yourself.
In the end hopefully combining the Pre-Baked and Real-Time will give you the best experience and illusion in the game.
Export to UE4
Exporting to UE4 is rather easy today in Houdini. For Pre-Baked Simulations, there is the RBD to FBX ROP node which is part of the GameDev tools for Houdini. There are also similar tools to just save out an FBX to use together with Unreal‘s Apex system for destruction.
For more information, check out this short tutorial by Luiz Kruel:
I advise working with un-triangulated source meshes since fracturing already triangulated meshes will generate additional unnecessary meshes. Sometimes as much as a 30% increase. That goes both for Real-Time and Pre-Baked assets.
Also, make sure to only fracture what actually needs to be fractured. If you end up with a lot of pieces that do not move, there is Destruction Cleanup tool in Houdini’s GameDev tools that can help you out. Here is a video about it:
In the video, you see that the destruction simulation is combined with tentacle one. The tentacle simulation is a Pre-Baked simulation made in Houdini that I imported as a FBX animation to UE4.
By adding different types of constraints, such as ConeTwist, Glue or Hard constraints and directing your pieces with the attributes “i@animated” and “i@active” you have a very powerful way to direct your simulations. This is how I made sure only the pieces close to the tentacle got destroyed first, and that in the end, the entire pillar explodes under the pressure knocking the tentacle out. It’s simply just flipping the “i@animated” from 1 to 0 at a given time.
And to get the PreBaked simulations into Unreal I use the RBD to FBX ROP node in Houdini from the previously mentioned GameDev tools in Houdini.
Houdini Tools Alternatives
There are fracturing tools within UE4 but I would say that for now, if you want it to look good you should probably set it up yourself in a external program such as Houdini.
Find more simulation tests on the artist’s ArtStation page;