Nothing can flatten your enthusiasm as much as watching your enemies vanish without so much as a whimper when you destroy them. It’s not uncommon to expect that our in-game actions carry some manner of weight. Failing to meet those expectations can lead to disappointment in our players.
It’s time to create some juicy eye candy to address this issue.
Create an enemy explosion effect.
I have created, imported my sprite sheets into Unity, and sliced them accordingly. I will start by using the first frame by dragging it into my scene.
Dragging the sprite into the scene will accomplish two things: It will automatically create a new GameObject in my Hierarchy. It will also add the SpriteRenderer Component to that GameObject.
Next, I will add the Animator Component to my new GameObject.
I will then create the Animation for the explosion.
The animation looks good. But I did say I was going to make it juicy. And being as I am a man of my word, juicy, I shall make it.
I am going to use a particle system to enhance the animation. The random particle values will break up the visuals of the explosion. Hiding the fact that all enemies explode in the same way should make the game more appealing.
I’ll add a new ParticleSystem Component to my GameObject. after adjusting some settings, I am ready to start some scripting.
Note: The ParticleSystem Component is a complex subject that I plan on writing about in a different article.