teststrecke-game/scripts/rounds_selection.gd
2024-11-09 14:27:34 +01:00

14 lines
283 B
GDScript

extends OptionButton
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
select(3-1) #preselect rounds
Gamestate.setRounds(3)
func _on_item_selected(index: int) -> void:
Gamestate.setRounds(index+1)
print("Set rounds to "+str(index+1))