add props
This commit is contained in:
@@ -1,4 +1,18 @@
|
||||
class_name PauseMain extends VBoxContainer
|
||||
|
||||
func _ready() -> void:
|
||||
visible = true
|
||||
visible = false
|
||||
$HBoxContainer/ItemList.item_selected.connect(onItemSelected)
|
||||
|
||||
func open():
|
||||
visible = true
|
||||
$HBoxContainer/ItemList.clear()
|
||||
|
||||
func close():
|
||||
visible = false
|
||||
|
||||
func isOpen() -> bool:
|
||||
return visible
|
||||
|
||||
func onItemSelected(index:int) -> void:
|
||||
print("Selected item index: ", index)
|
Reference in New Issue
Block a user