Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- extends KinematicBody
- func _physics_process(delta):
- var move = Vector3()
- # movimento sinistra destra
- if Input.is_action_pressed("ui_left"):
- move.x = -1
- if Input.is_action_pressed("ui_right"):
- move.x = 1
- # movimento aventi indietro asse z
- if Input.is_action_pressed("ui_down"):
- move.z = 1
- if Input.is_action_pressed("ui_up"):
- move.z = -1
- # movimento alto/basso
- if Input.is_action_pressed("ui_page_up"):
- move.y = 1
- if Input.is_action_pressed("ui_page_down"):
- move.y = -1
- move_and_slide(move)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement