10 lines
221 B
GDScript
10 lines
221 B
GDScript
|
|
extends Node3D
|
||
|
|
|
||
|
|
@onready var animation_player: AnimationPlayer = $AnimationPlayer
|
||
|
|
|
||
|
|
func _on_lever_changed(isUp: bool) -> void:
|
||
|
|
if isUp:
|
||
|
|
animation_player.play("CoffinOpen")
|
||
|
|
else:
|
||
|
|
animation_player.play("CoffinClose")
|