Godot Version
Godot 4
Question
Hi, im new
I was trying to recapture the cursor once is out of the camera of the player
This is the code
func _process(delta):
if Input.is_action_just_pressed(“ui_cancel”):
Input.set_mouse_mode(Input.MOUSE_MODE_VISIBLE)
if Input.MOUSE_MODE_VISIBLE:
Input.is_action_just_pressed(“ui_cancel”)
Input.set_mouse_mode(Input.MOUSE_MODE_CAPTURED)
I dont know if i need to do or add something else or if i have to map a new key to make it work properly