meow
This commit is contained in:
parent
1a5c9d3425
commit
bcbe8ab287
6 changed files with 53 additions and 22 deletions
|
|
@ -1,6 +1,7 @@
|
|||
extends Camera2D
|
||||
|
||||
@export var camera_speed : float = 10
|
||||
var current_speed : float = 0
|
||||
var active : bool = false
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
|
|
@ -11,7 +12,8 @@ func _ready() -> void:
|
|||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta: float) -> void:
|
||||
if active:
|
||||
position.x += delta * camera_speed
|
||||
current_speed = clampf(current_speed + 10* delta,0,camera_speed)
|
||||
position.x += delta * current_speed
|
||||
|
||||
|
||||
func _on_lander_moved() -> void:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue