コード例 #1
0
        /// <summary>
        ///     Runs in the background of the game (another thread), polls for new updates
        ///     from the clients.
        /// </summary>
        private void ProcessEvents()
        {
            while (Status == ServerStatus.Running)
            {
                // Poll for new events
                _netServer.PollEvents();

                // Wait
                Thread.Sleep(15);
            }
        }
コード例 #2
0
ファイル: Client.cs プロジェクト: slimlime/Tango
        /// <summary>
        ///     Runs in the background of the game (another thread), polls for new updates
        ///     from the server.
        /// </summary>
        private void ProcessEvents()
        {
            // Run this loop while we are connected or if we are still trying to connect.
            while (Status == ClientStatus.Connected || Status == ClientStatus.Connecting)
            {
                // Poll for new events
                _netClient.PollEvents();

                // Wait
                Thread.Sleep(15);
            }
        }
コード例 #3
0
ファイル: Client.cs プロジェクト: woodybriggs/Tango
 /// <summary>
 ///     Polls new events from the server.
 /// </summary>
 public void ProcessEvents()
 {
     // Poll for new events
     _netClient.PollEvents();
 }
コード例 #4
0
 /// <summary>
 ///     Polls new events from the clients.
 /// </summary>
 public void ProcessEvents()
 {
     // Poll for new events
     _netServer.PollEvents();
 }