N
N
NickName73312018-08-19 17:52:39
C++ / C#
NickName7331, 2018-08-19 17:52:39

Unity(C#) - How to properly pause the game?

By pressing the button, a pause window opens where there are three more buttons: continue the game, settings, exit. So that nothing happens in the game during the pause, I used timeScale = 0, but because of this, the buttons cannot be pressed either. How can I stop the whole game except the pause window?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
Konstantin Kitmanov, 2018-08-20
@NickName7331

In addition to Time.timeScale = 0, you must also remember to turn off all scripts related to mouse movements (moving around the map in rts / tower defense, mouse look in first / third person actions, etc.)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question