/// <summary> /// Initializes a new instance of the CustomerViewModel class. /// </summary> public CustomerViewModel(Customer customer) { _customer = customer; _socketManager = SimpleIoc.Default.GetInstance <TcpSocketManager>(); AddMoneyCommand = new RelayCommand <float>(AddMoney); TakeMoneyCommand = new RelayCommand <float>(TakeMoney); }
public ControllerTracking(int pUserId, string pSessionId, TcpSocketManager pTcpSocketManager) { userId = pUserId; sessionId = pSessionId; tcpSocketManager = pTcpSocketManager; EVRInitError eError = EVRInitError.None; vr_pointer = OpenVR.Init(ref eError, EVRApplicationType.VRApplication_Background); }
public ControlViewModel(MainWindowViewModel mainWindowViewModel, TcpSocketManager pTcpSocket, SessionID pSessionId) { //ToDo change hardcoded Variables tcpSocketManager = pTcpSocket; userId = pSessionId.m_owner; sessionId = pSessionId; _udpPort = Int32.Parse(mainWindowViewModel.LoginViewModel.UdpPortTextBoxViewModel.Value); _udpIpAdress = mainWindowViewModel.LoginViewModel.ServerIpTextBoxViewModel.Value; _vrManager = new VrManager(userId, pSessionId.m_name, tcpSocketManager); VrManager.CloseVredEngine(); _vrManager.StartVredEngine(); _mainWindowViewModel = mainWindowViewModel; LeaveRoomCommand = new LeaveRoomCommand(this); HeadTracking = false; ControllerTracking = false; resultClipPlaneFloat = new SharedState <List <float> >("ClipPlane", new List <float>() { 1, 2, 3, 4, 5, 6, 7 }); resultClipPlaneFloat.setUpdateFunction(OnClipPlaneVrbUpdate); StartConnectToVredSocket(); StartReceiverFromVred(); }
void Awake() { instance = this; tcpSocket = new TcpSocket(); }
public void initializeSender(TcpSocketManager sender) { tcpSocket = sender; }
public TcpSocketManagerTests() { logger = MockGenerator.Get <ILogger>(); tcpSocketManager = new TcpSocketManager <Message, Message>(logger); }
public VrManager(int pUserId, string pSessionId, TcpSocketManager pTcpSocketManager) { userId = pUserId; session = pSessionId; tcpSocketManager = pTcpSocketManager; }
void Shutdown() { if(SocketManager != null) { try { Debug.Log("shutdown"); // _socket.Shutdown(SocketShutdown.Both); SocketManager = null; LoginScene.SetActive(true); LobbyScene.SetActive(false); } catch(Exception e) { Debug.LogError("Sutdown Exception : " + e.Message); SocketManager = null; } } }