I’m developing a game that has a tutorial level. This tutorial level shows you an informative message when you collide with a trigger box. The game controls are:
- typical WASD for movement
- SPACE for jump
- and mouse for camera yaw.
I want the game to stop any input (not WASD movement, not jumping and not yaw from the mouse). To do that, I thought about two ways:
- Pause the game and show a widget screen over it and then un-pause it.
- Disable any input movement from user.
Right now I’m using the second method like this:
After that, when I press the OK button on the message screen, I revert the Set Ignore Move Input and the Set Ignore Look Input. But when I do so, my mouse is in the same position as the accept button is, and I recover the control in that place. When you push more than one button, it gets annoying :S
One solution would be to set the mouse position in the screen center, so, my first question would be:
Is there any way in which I can set the mouse position to the center of the screen?
Since now I tried this:
but I don’t know what to to with that Set Mouse Position…
So my question will be: I know there are games that allow you to insert messages, stop gameplay, and then give control back to the user. Is this the correct way to do so?