frame-of-mind/src/base-environments/youth_room/youth_light_animation.gd

14 lines
369 B
GDScript

extends AnimationPlayer
func _ready() -> void:
Scenes.scene_finished.connect(lights_on)
Scenes.scene_starting.connect(lights_off)
func lights_off(id: int = -1, _repeat: bool = false):
if id == Scenes.id.YOUTH_VOICE_TRAINING:
await get_tree().create_timer(10).timeout
queue("lights_out")
func lights_on(_id: int = -1, _repeat: bool = false):
queue("light_up")