Un peu de musique dans ce monde de brutes
This commit is contained in:
@@ -23,9 +23,13 @@ func moveTo(position: Vector2) -> void:
|
||||
func updateFacingDirectionInAnimationTree():
|
||||
animation_tree.set("parameters/CarStates/driving/blend_position", last_facing_direction)
|
||||
animation_tree.set("parameters/CarStates/idling/blend_position", last_facing_direction)
|
||||
|
||||
func _ready() -> void:
|
||||
$AudioStreamPlayer2D.play()
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta: float) -> void:
|
||||
$AudioStreamPlayer2D.pitch_scale = current_speed / speed
|
||||
$ZIndexControler/ShapeCast2D.enabled = !$CollisionHorizontal.disabled
|
||||
var accelerationStep = (speed * delta / timeToChangeVelocity)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user