1 min read

Source: Roblox Creator Hub · CC BY 4.0 · View source · Code samples: MIT Imported 2026-10-03. Formatting adapted for this site.

ControlMode

The ControlMode Enum sets how the player is controlled.

Note that shift-lock related APIs are in the process of being deprecated, so it's recommended to use UserInputService.MouseBehavior instead to lock the mouse.

Items

NameValueDescription
Classic0Allows the camera to be moved by clicking and dragging with the right mouse button.
MouseLockSwitch1Similar to classic, but allows the player to toggle mouse locking, causing the camera to rotate as the player moves the mouse (without holding down a button).

Classic

Allows the camera to be moved by clicking and dragging with the right mouse button.

FieldValue
value0

MouseLockSwitch

Similar to classic, but allows the player to toggle mouse locking, causing the camera to rotate as the player moves the mouse (without holding down a button).

FieldValue
value1