diff options
| author | realtradam <[email protected]> | 2020-03-15 14:31:34 -0400 |
|---|---|---|
| committer | realtradam <[email protected]> | 2020-03-15 14:31:34 -0400 |
| commit | c65f6805081e999fa231f71b231dba6dc05286ea (patch) | |
| tree | 5365cc9bca9fc05b7c9bc26858335fdd3b5ede68 /Racing-Game/KinematicBody2D.gd | |
| parent | 007e9dab410d825e92b0d391fd8356efcb4cb5db (diff) | |
| download | optimal-direction-c65f6805081e999fa231f71b231dba6dc05286ea.tar.gz optimal-direction-c65f6805081e999fa231f71b231dba6dc05286ea.zip | |
more organizing file structure, not done yet
Diffstat (limited to 'Racing-Game/KinematicBody2D.gd')
| -rw-r--r-- | Racing-Game/KinematicBody2D.gd | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/Racing-Game/KinematicBody2D.gd b/Racing-Game/KinematicBody2D.gd deleted file mode 100644 index 34844a4..0000000 --- a/Racing-Game/KinematicBody2D.gd +++ /dev/null @@ -1,21 +0,0 @@ -extends KinematicBody2D - -const UP = Vector2(0, -1) -var motion = Vector2() - -func _physics_process(delta): - - if Input.is_action_pressed("ui_right"): - motion.x = 100 - elif Input.is_action_pressed("ui_left"): - motion.x = -100 - else: - motion.x = 0 - - if is_on_floor(): - if Input.is_action_just_pressed("ui_up"): - motion.y = -325 - - motion.y += 10 - motion = move_and_slide(motion, UP) - pass |
