Added missing data
This commit is contained in:
23
godot/main/main.gd
Normal file
23
godot/main/main.gd
Normal file
@@ -0,0 +1,23 @@
|
||||
extends Spatial
|
||||
|
||||
|
||||
# Declare member variables here. Examples:
|
||||
# var a = 2
|
||||
# var b = "text"
|
||||
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready():
|
||||
pass # Replace with function body.
|
||||
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta):
|
||||
if Input.is_action_pressed("forward"):
|
||||
$Camera.global_transform.origin += -$Camera.global_transform.basis[2] * delta * 100.0
|
||||
elif Input.is_action_pressed("backward"):
|
||||
$Camera.global_transform.origin += $Camera.global_transform.basis[2] * delta * 70.0
|
||||
if Input.is_action_pressed("left"):
|
||||
$Camera.rotate_y(5.0 * delta)
|
||||
elif Input.is_action_pressed("right"):
|
||||
$Camera.rotate_y(-5.0 * delta)
|
||||
Reference in New Issue
Block a user