String startPath; // The Unity Application Starting Path // Start UDP Socket void Start() { if (hasVREnvironment) { // // Start Python Server Automatically // startPath = Application.dataPath; // String path = startPath + "/Gesture/Scripts/StartServer.bat"; //Resource.load // pythonServer.StartInfo.FileName = path; // Initial pythonServer Path // // Set the window off // pythonServer.StartInfo.UseShellExecute = true; // pythonServer.StartInfo.CreateNoWindow = true; // pythonServer.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden; // pythonServer.Start(); // Start Python Socket pythonServer.StartInfo.FileName = "CMD.exe"; pythonServer.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden; if (isBuiltGame) { pythonServer.StartInfo.Arguments = "/C python PythonSocket/Server.py"; } else { pythonServer.StartInfo.Arguments = "/C python Assets/Gesture/Scripts/Server.py"; } pythonServer.Start(); // Start Unity Server Debug.Log("Socket Initial"); socket = new UdpSocket(); socket.InitSocket(); } }