void Update()
    {
        if (_isAtStartup)
        {
            if (Input.GetKeyDown(KeyCode.S))
            {
                Server.StartServer();
                Client.ConnectLocally();
                _isAtStartup = false;
            }

            if (Input.GetKeyDown(KeyCode.X))
            {
                Server.StartSinglePlayerServer();
                Client.ConnectLocally();
                _isAtStartup = false;
            }

            if (Input.GetKeyDown(KeyCode.C))
            {
                Client.ConnectToHost(ServerHostname);
                _isAtStartup = false;
            }
        }
        else if (_isConnected && !_isWaiting)
        {
            if (Input.GetKeyDown(KeyCode.P))
            {
                _isWaiting = true;
                Client.SendActions(new List <GameAction>());
            }
        }
    }
 void Update()
 {
     if (_isAtStartup)
     {
         if (_isPlayingSolo)
         {
             Server.StartSinglePlayerServer();
             Client.ConnectLocally();
             _isAtStartup = false;
         }
         else if (_amIHost)
         {
             Server.StartServer();
             Client.ConnectLocally();
             _isAtStartup = false;
         }
         else
         {
             Client.ConnectToHost(ServerHostname);
             _isAtStartup = false;
         }
     }
 }