public void SetUpConnection() { PlayerConnectionInfo = new PlayerConnectionInfo { Name = _view.PlayerName, RemoteAddress = _view.PlayerIp }; }
public void ReadyConnection(PlayerConnectionInfo playerConnectionInfo) { throw new System.NotImplementedException(); }
public void SetPlayerRelatedData() { var playerConnectionView = new PlayerConnectionView(); var playerConnectionController = _network.ConnectionType == ConnectionType.Server ? new PlayerConnectionController(playerConnectionView, false) : new PlayerConnectionController(playerConnectionView, true); playerConnectionView.SetController(playerConnectionController); if (playerConnectionView.ShowDialog() == DialogResult.OK) { _playerConnectionInfo = playerConnectionController.PlayerConnectionInfo; Common.IpEndPoint = _playerConnectionInfo.RemoteAddress != null ? new IPEndPoint(_playerConnectionInfo.RemoteAddress, 2000) : new IPEndPoint(IPAddress.Parse("127.0.0.1"), 2000); } _localPlayer.Name = playerConnectionController.PlayerConnectionInfo.Name; }