public void CalibratePupilLabs() { if (calibrationController.subsCtrl.IsConnected) { calibrationController.StartCalibration(); calibrationController.OnCalibrationSucceeded += CalibrationSuccessful; calibrationController.OnCalibrationFailed += CalibrationFailed; pauseUI.SetActive(false); infoText.gameObject.SetActive(false); } else { infoText.text = "PupilLabs tracker disconnected!\n If the tracker was selected in the JSON settings, ensure Pupil Capture is running and try again."; infoText.color = Color.red; } }
public void NewGame() { ResetVars(); //Init LogWriter _logWriter = new LogWriter(Application.persistentDataPath + "\\Logs\\" + System.DateTime.Now.ToString("dd-MM-yyyy HH'h'mm'm'ss's'") + "\\"); //Init MqttManager _udpHost.SetClient(gameSettings.ClientIp, gameSettings.ClientPort); _udpHost.Connect(); //Init calibration _calibrationController.StartCalibration(_udpHost); //Apply game settings _speed = gameSettings.GameSpeed; _spawnSpacing = gameSettings.CubeSpacing; _distanceFromMiddle = gameSettings.DistFromMiddle; _cubeCount = gameSettings.CubeCount; }