It says 'Cursor' does not contain a definition for 'locked'

It says
‘Cursor’ does not contain a definition for ‘locked’. Please Help

It is correct. Cursor does not contain a definition flor ‘locked’. Check your code. It should be

Cursor.lockState = CursorLockMode.Locked;

Privacy & Terms