Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Enum.MouseBehavior.LockCenter Doesn't work unless looped?

Asked by 4 years ago

Using The Sample Code Below from my script Doesn't seem to work unless my mouse is clicked inside of the game window beforehand. It works fine if I loop it, but then i'm not able to toggle it back to it's default mouse behavior so I can access guis.

wait(1)
camera.CameraType = Enum.CameraType.Scriptable
main.uis.MouseIconEnabled = false
main.uis.MouseBehavior = Enum.MouseBehavior.LockCenter

Answer this question