// +++ event handler ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    public async void OnLoginAsPlayerClicked(int playerId)
    {
        Debug.Log("OnLoginAsPlayerClicked called");

        // invoke event to show waiting screen
        _sceneManager.LoadScene("menuWaiting");

        // Wait for the networkmanger to connect the player
        await _networkManager.LoginPlayerAsync(playerId);

        // then invoke event to open match options
        _sceneManager.LoadScene("menuMatchOptions");
    }
Exemple #2
0
    async Task UpdateServerSettings()
    {
        await _networkManager.LoginPlayerAsync(_playerIndex);

        await _networkManager.UpdatePlayerSettingsAsync(_userName.text);
    }