How to make animation play when game is paused in Unity

Animations make a game look alive. In Unity, we can do a lot of things like changing the animation speed, playing random animations, slow motion and so on. Animation can be used to make UI look good but when you pause your game the animations also pause. In this tutorial, we will see how to make the animation play when your game is paused.

There are two ways to pause your game in Unity. One is using Unity time.timescale and the other one is using a singleton. If you are using a singleton to pause your game then the animation should work by default. But if you are using time.timescale then all-time related activities are paused and so are the animations.

If you have animations on your pause menu. This is how you can make it work.

Select the gameobject to which the animator component is attached.

Free Unity asset banner

Go to inspector window >Animator component

Set Update mode to Unscaled Time.

Now your animation will play even when your game is paused.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.