extends Control # Called when the node enters the scene tree for the first time. func _ready() -> void: WSClient.lobby_joined.connect(_on_lobby_joined) func _on_lobby_joined(lobby: String) -> void: GameData.lobby_code = lobby get_tree().change_scene_to_file("res://Multiplayer/Multiplayer.tscn") # Called every frame. 'delta' is the elapsed time since the previous frame. func _process(delta: float) -> void: pass func _on_host_button_pressed(): GameData.is_player_black = false WSClient.start(GameData.WEBSOCKET_ENDPOINT, "") func _on_join_button_pressed(): get_tree().change_scene_to_file("res://UI/join_menu.tscn") func _on_exit_button_pressed(): get_tree().quit()