Our VFX specialist wrote this blog on stylized explosions! You can read the full article and view the images he is referencing here:
Dev's take on stylized VFX in Unity
Creating Stylized Explosion VFX in Unity!
Ryan Bradford
Welcome!
Stylized games have seen a massive surge to the forefront of the gaming industry, and it just so happens that I am working on one!
Ringleaders
In this post I will explain the way that I approach an effect like this, how you might apply some artistic principles to your own, and some general tips at the end for the unity particle system.
Here's a look at the explosion I'll be referencing throughout this post:
The Boom
What is the most important part of the explosion? The BOOM! So, first things first, it is important to understand how you want your boom to appear. Looking at a conventional explosion we can break it up into a couple of sections:
The explosion is initiated
This can be any sort of signal or implication that a blast is about to happen. In the example, a mine is placed and then begins activating. It is important to use this to telegraph to the player what is about to happen so they know to run! This section can be anything from a couple of particles being sucked into the center, to an entire pre-explosion animation sequence.
The Sun Phase
If you look closely you can see that right at the start of the explosion there is the most intense color and heat.
This should be communicated through your initial particle burst. Typically this is made up of a bright flash followed by a ball of the brightest/most intense color you want present in the effect. It's important that the Sun Phase only lasts a moment* so that the rest of the explosion can play out.
* -- This is how traditional explosions work, and by no means are you limited to keeping this short if your explosion should be slowed down or last longer than usual.
The BOOM
Now comes the blast! Here we get the typical smoke cloud and explosion of debris that you find in most grenade and bomb effects. I feel this is the best place for artistic expression because this phase typically lasts a second or two and is easily visible during run time. In a stylized effect, it can be fun to make up shapes that your smoke cloud takes on, create layering with multiple clouds, and use colors that typically aren't found in real life explosions. In the example above you can see we're using a noise texture on our expanding spheres of post Sun Phase smoke. Additionally we've layered multiple effects to create a shadow cloud that generates a lot of contrast with the larger red cloud.
Some good options for play here can be to change the shape of your expanding mesh or try different color combinations (vibrating colors are a great place to start!).
The Particles
Now that we have covered the basic approach, it's time to discuss how to actually get there. The Unity particle system is pretty intricate, and I would highly recommend you take a look at it before continuing because particles can be tricky little goobers. Some other great resources are Gabriel Aguiar and VFX Apprentice.
One more thing before you go deeper, it would be wise to brush up on your photoshop skills at this point. The particles are where an understanding of 2D painting and technical know-how come together.
Now then, on to the particles. As you begin with the pre-existing Unity particle system, there are a couple of useful effects that deliver a lot of impact. The first of these is the size over lifetime effect. This allows you to directly tie the scale of your object to a curve that is driven by the lifetime value of your particles. With a curve like this, you can achieve common animation principles like squash and stretch easily. Additionally, you can split the size over lifetime into separate axes allowing for more explicit control over dimensions. Here's an example of one of my own curves I like to use:
The second useful setting on the particle effects that will help create your explosions is the color over lifetime effect. This does the same thing as size over lifetime but for color! Together these two can be used to exaggerate your particles main effects, or create very subtle tertiary particles that support the main effect. Hand in hand, these two will go a long way to making your particle effects look and feel more alive and professional.
Materials & Shadergraph
The use of materials and shaders could be their own post entirely (and likely will be!) so I will keep this section brief. The most important thing to know here is the use of basic shader graph functions. Things like scrolling textures, screen space rendering, and timers are incredibly useful, and should not be underestimated when considering how to approach an effect. Many effects can forgo particles altogether if they make clever use of animators and a well made material. That being said, it is useful to know that for the explosion in our demonstration above, I made use of one important node that you will all find useful when creating many things.
The Voronoi node is a simple math based noise that is seriously useful. It is found just about everywhere these days, from textures made in Substance Designer, to procedural terrain generation in voxel games. Voronoi is definitely something that should be in your artist's toolbelt from here on out. Use it to create the wavy shell of the explosion like I did above, or use it to create a wood grain by stretching your UV's, you can even use it to make stylized tornadoes. No matter what effect you're considering, a useful noise texture can be what it takes to push it that extra mile.
In Conclusion
I hope you learned something useful! As I previously mentioned, this post is meant to be an introductory exploration into creating stylized effects. So, hopefully you have gained some knowledge that can be applied to your future effects! Thank you so much for taking the time to read this, and please do reach out if you have any questions. Have a great day :)