RetroDECK/tools/configurator/components/popup.gd

20 lines
420 B
GDScript3
Raw Normal View History

2024-01-11 18:19:16 +00:00
extends Control
var content = null
# Called when the node enters the scene tree for the first time.
func _ready():
if (content != null):
$Panel/VBoxContainer/ContentContainer.add_child(content)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):
pass
func set_content(new_content):
content = load(new_content).instantiate()
func _on_back_pressed():
queue_free()