Member-only story

Unity2D DevLog 13— They Shoot Back!

Claudio Grassi
2 min readJun 3, 2021

Dodging enemies in the game could become a little too easy and repetitive. Therefore, I took a step further in trying to vary the style of gameplay. Time to create a new enemy!

Objective:

Provide enemy characters with the ability to shoot back.

How I went about it:

This shooting mechanic was not difficult to add. I had most of the necessary components already created. All I had to add was a Script to handle the shooting mechanic.

But first, I had to adapt an enemy sprite to make the new enemy. It seems like a good idea to differentiate enemies so that the player can react to them appropriately. All I did for this one was to re-color the sprite. I like how it looks tho.

Now that the player can identify a threat, it’s time to create the Shooting Script. This script will allow the alien to detect the player and fire a bullet.

--

--

Claudio Grassi
Claudio Grassi

Written by Claudio Grassi

Experienced digital artist, Unity game developer & coder with a knack for problem solving and a passion for video games.

No responses yet