Animation of 2D sprites in Unity is fun :)

Samarth Dhroov
2 min readMay 14, 2021

--

Animation Sprites

One could imagine 2D sprites as a series of relevant images set in an order which upon a successful run in a single stretch gives an illusion of movement. That is also the core of films and animation.

In Unity, we achieve animation of pre-built sprites using the animation toolkit.

As you can see below, the powerup is a falling image sprite and upon collision with the player, it disappears and allows the player some extra bullet power.

Unity

Let us animate it to make it look far more interesting.

  • Open the animation window and snap it right beside the game view.
Unity Animation
  • Select the animation tab where the “Create” option is visible. Click on it and give a name of choice to the animation in process and save it in the animation folder.
Unity Animation
  • Select the object that you are about to animate, go to the animation window, and then drag the sprites associated with the object into dopesheet.
Unity Animation
  • Click the red record button and record the animation by play button and then again stop the record button to complete the process.
Unity Animation
  • here, the final result shall be verified by observing the following signs.
Unity Animation
  • If it somehow fails to attach the animation, it could be assigned manually also by first, adding an animator component and then filling the controller box from the project’s animation folder having the recorded animation.
  • The final result is now in place :)
Unity Animation

Thank you very much

--

--

No responses yet