Files
chaussette.sale/scenes/pathFollow.gd
Thomas fe463ad396 Initial commit
Un bout de jeu, qui fait pas grand chose mais on progresse.
2025-02-21 17:59:47 +01:00

14 lines
432 B
GDScript

extends PathFollow2D
@export var speed = 0.1
var voiture
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
voiture = (self.get_child(0) as Voiture)
voiture.updatePosition(position.x, position.y)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
progress_ratio += delta * speed;
voiture.updatePosition(position.x, position.y)