Let’s make it glow!

Yesterday we added a collectible powerup object so that our player has something to grab and activate the new nifty triple shot powerup we have given them. When we setup the object, we used the first image in a series of images meant to be made into an animation that makes it look like our power up is blinking. Now we’re going to create that animation and apply it to our new collectible!

First we’re going to select our prefab and click the open prefab button to enter into the dedicated prefab editing view.

Now, with our prefab object selected we can open our animation window by clicking Window > Animation > Animation. Then we’ll click on the create button and give our new animation (and associated animator object) a name.

To create our animation, click the record button that looks like a red circle and then drag our set of images into the timeline displayed in our Animation window. This should automatically assign 1 image per frame. We can press the play button to test the animation.

Click the back arrow at the top of the prefab hierarchy view to return to our normal scene view. now we can test to make sure our power up animation is working!

Next Time!

Today we looked at how to animate our powerup sprites and make it look flashy! Tomorrow we’ll talk about how long our powerups should remain active! If you enjoyed this article, or want to come along with me as I progress on my journey, follow me at gamedevchris.medium.com.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Christopher West

Christopher West

Unity Game Developer, Software Engineer, Gamer, Musician, and Father. Christopher is a creative that enjoys a challenge and loves coding.