mirror of
https://github.com/stevenhowes/GodotTest.git
synced 2026-05-27 00:03:28 +01:00
Normalise so we don't get extra speed on diagonals
This commit is contained in:
@@ -17,6 +17,8 @@ func _physics_process(_delta):
|
|||||||
|
|
||||||
update_animation_parameters(input_direction)
|
update_animation_parameters(input_direction)
|
||||||
|
|
||||||
|
input_direction = input_direction.normalized()
|
||||||
|
|
||||||
velocity = input_direction * move_speed
|
velocity = input_direction * move_speed
|
||||||
|
|
||||||
pick_new_state()
|
pick_new_state()
|
||||||
|
|||||||
Reference in New Issue
Block a user