V
V
Vladimir2021-08-19 21:40:51
C++ / C#
Vladimir, 2021-08-19 21:40:51

How to pause the game if the game is connected with a mouse?

The problem is that through Time.timeScale all this is set. Objects in the game freeze, but since the gameplay itself is based on the rotation of the mouse and shooting on click, when the Canvas opens, the character continues to rotate in the direction of the mouse and can shoot. At the same time, the cartridge itself only spawns, and starts flying only after exiting the pause. How can this be bypassed?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
Nik Faraday, 2021-08-22
@NikFaraday

Block this function with a script if it has access, or bring some element on top that will technically block the element below

N
Nikita Polishchuk, 2021-08-23
@PNECtarine

You can set a condition: rotates only if timescale != 0

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question