goodnight_jellybean/godot/assets/audio/AmbientSound.gd

17 lines
366 B
GDScript3
Raw Normal View History

2023-01-01 02:23:56 -07:00
extends Node
onready var drone_fsm: AnimationNodeStateMachinePlayback = $DroneAudioFSM.get("parameters/playback")
func _ready():
$NormalDrone.play()
yield(get_tree().create_timer(.1), "timeout")
$SicklyDrone.play()
func _on_AnimationTree_motion_status(value):
if value:
drone_fsm.travel("play_sickly_drone")
else:
drone_fsm.travel("play_normal_drone")