velocity is reset upon respawning
This commit is contained in:
parent
3fcee8f5fc
commit
0e8d89aa5f
1 changed files with 3 additions and 0 deletions
|
@ -69,6 +69,9 @@ func _unhandled_input(event: InputEvent) -> void:
|
||||||
$DebugMenu.visible = !$DebugMenu.visible
|
$DebugMenu.visible = !$DebugMenu.visible
|
||||||
elif event.is_action_pressed(&"freeroam_respawn"):
|
elif event.is_action_pressed(&"freeroam_respawn"):
|
||||||
self.position = startPosition
|
self.position = startPosition
|
||||||
|
walk_vel = Vector3(0, 0, 0)
|
||||||
|
jump_vel = Vector3(0, 0, 0)
|
||||||
|
grav_vel = Vector3(0, 0, 0)
|
||||||
elif event.is_action_pressed(&"freeroam_flashlight_zoom_in"):
|
elif event.is_action_pressed(&"freeroam_flashlight_zoom_in"):
|
||||||
if ($Camera/Flashlight.visible):
|
if ($Camera/Flashlight.visible):
|
||||||
if ($Camera/Flashlight.spot_angle > 2):
|
if ($Camera/Flashlight.spot_angle > 2):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue