@tool extends VBoxContainer class_name Alert @export var title = "" : set(t): title = t if is_node_ready(): %TitleLabel.text = t @export var text = "" : set(t): text = t if is_node_ready(): %TextLabel.text = t func _ready(): title = title text = text func appear( with_anim : bool = not visible ): if with_anim : %AppearAnimationPlayer.play("appear") else: %AppearAnimationPlayer.play("shown") func disappear( with_anim : bool = visible ): if with_anim : %AppearAnimationPlayer.play_backwards("appear") else: %AppearAnimationPlayer.play("hidden")