Example #1
0
        public TgcNetworkingModifierServersDialog(TgcNetworkingModifierControl networkingControl, string clientName)
        {
            InitializeComponent();

            this.networkingControl = networkingControl;
            textBoxClientName.Text = clientName;
        }
        /// <summary>
        ///     Crea el modificador de Networking
        /// </summary>
        /// <param name="varName">Identificador del modifier</param>
        /// <param name="serverName">Nombre default que va a usar el servidor</param>
        /// <param name="clientName">Nombre default que va a usar cada cliente</param>
        /// <param name="port">Puerto en el cual se va a crear y buscar conexiones</param>
        public TgcNetworkingModifier(string varName, string serverName, string clientName, int port)
            : base(varName)
        {
            Server            = new TgcSocketServer();
            Client            = new TgcSocketClient();
            this.port         = port;
            clientConnected   = false;
            networkingControl = new TgcNetworkingModifierControl(this, serverName, clientName);
            AvaliableServers  = new List <TgcSocketClient.TgcAvaliableServer>();

            newConnectedClients = new Queue <TgcSocketClientInfo>();
            disconnectedClients = new Queue <TgcSocketClientInfo>();
            ;

            contentPanel.Controls.Add(networkingControl);
        }
Example #3
0
        public TgcNetworkingModifierClientsDialog(TgcNetworkingModifierControl networkingControl)
        {
            InitializeComponent();

            this.networkingControl = networkingControl;
        }