- Home /
Duplicate Question. http://answers.unity3d.com/questions/62440/how-to-stop-mouse-going-out-of-the-screen-.html
How to keep my cursor inside window boundaries
I am making my game in windowed mode and the cursor is free to use. The cursor can move over the boundary of the game window. How do I keep the cursor only inside the window, like in a RTS game?
This also happens in fullscreen mode when my second display is connected - when the cursor is moved to the side it rolls onto the other screen. How do I keep the cursor from leaving the game window?
Have you changed something in the default settings? If I start my 2D game it just works fine.
No i haven't changed default settings.
Are you using windowed mode or dual monitors? because if your using either the cursor will move out of the window.
I'm wondering about this too. Disappointing that nobody has offered a solution for what seems like a simple problem.
Duplicate question. There is a good discussion here: http://answers.unity3d.com/questions/62440/how-to-stop-mouse-going-out-of-the-screen-.html
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Help In Making a SphereCast for 3D Tire! Working RayCast Script included! 0 Answers
2D sprites, Negative scaling flips my look at mouse 0 Answers
Rotating object with a mouse movement 0 Answers
How to execute action with two keys when they are alredy tied to other actions? 2 Answers