DuckRun/scenes/hindernis/hindernis.gd
megamichi 431fb8220e - implementing biom change
- fixing typo in "highscore"
2024-10-18 16:34:51 +02:00

13 lines
246 B
GDScript

extends CharacterBody2D
@onready var speed = 0
func _ready() -> void:
$"Sprite".frame = randi_range(0,4)
func _process(delta: float) -> void:
speed = $"..".speed
global_position.x -= speed*delta
if global_position.x < -30:
queue_free()