Exemplo n.º 1
0
        /// <summary>
        /// Private constructor for NetworkContext; NetworkContexts can only be created using the
        /// static helper methods.
        /// </summary>
        /// <param name="localPlayer">The local player</param>
        private NetworkContext(Player localPlayer)
        {
            _dispatcher            = new NetworkMessageDispatcher();
            LocalPlayer            = localPlayer;
            _localPlayerEnumerable = new[] { localPlayer };

            _connectionMonitors = new List <INetworkConnectionMonitor>();
        }
Exemplo n.º 2
0
        /// <summary>
        /// Private constructor for NetworkContext; NetworkContexts can only be created using the
        /// static helper methods.
        /// </summary>
        /// <param name="localPlayer">The local player</param>
        private NetworkContext(Player localPlayer) {
            _dispatcher = new NetworkMessageDispatcher();
            LocalPlayer = localPlayer;
            _localPlayerEnumerable = new[] { localPlayer };

            _connectionMonitors = new List<INetworkConnectionMonitor>();
        }