Add my own part to move backwards on down
This commit is contained in:
parent
fc1fc0b784
commit
bbeb63cc62
1 changed files with 5 additions and 3 deletions
|
@ -11,8 +11,10 @@ func _process(delta):
|
|||
direction = +1
|
||||
rotation += angular_speed * direction * delta
|
||||
|
||||
var velocity = Vector2.ZERO
|
||||
var velocity = Vector2.UP.rotated(rotation) * speed
|
||||
if Input.is_action_pressed('ui_up'):
|
||||
velocity = Vector2.UP.rotated(rotation) * speed
|
||||
|
||||
position += velocity * delta
|
||||
|
||||
if Input.is_action_pressed('ui_down'):
|
||||
position -= velocity * delta
|
||||
|
||||
|
|
Loading…
Reference in a new issue