Spectator now captures mouse

This commit is contained in:
leca 2024-02-21 03:25:10 +03:00
parent 9bdeb1d1e4
commit 00ea617f39
1 changed files with 1 additions and 1 deletions

View File

@ -7,6 +7,7 @@ var walk = 2
func _ready(): func _ready():
camera.make_current() camera.make_current()
Input.set_mouse_mode(Input.MOUSE_MODE_CAPTURED)
func _unhandled_input(event): func _unhandled_input(event):
if Input.is_action_pressed("MWU"): if Input.is_action_pressed("MWU"):
@ -29,7 +30,6 @@ func _physics_process(delta):
var velocity = Vector3.ZERO var velocity = Vector3.ZERO
var speed var speed
if Input.is_action_pressed("run"): if Input.is_action_pressed("run"):
speed = walk * 2 speed = walk * 2
else: else: