How can i make the mouse pointer stay locked at the center of the screen, like the shift lock mechanic. I tried looking at the script for it but i don't see how it works
1 | -- Lock the mouse in the center of the screen |
2 | game:GetService( "UserInputService" ).MouseBehavior = Enum.MouseBehavior.LockCenter |
3 | -- Or you can lock the mouse where it is |
4 | game:GetService( "UserInputService" ).MouseBehavior = Enum.MouseBehavior.LockCurrentPosition |
5 | -- Reset the mouse back to it's normal state |
6 | game:GetService( "UserInputService" ).MouseBehavior = Enum.MouseBehavior.Default |