|
|
|
@ -31,13 +31,14 @@ public class ExperimentController : MonoBehaviour {
|
|
|
|
|
#if UNITY_STANDALONE_WIN
|
|
|
|
|
platform = "oculus";
|
|
|
|
|
#endif
|
|
|
|
|
platform = "mouse";
|
|
|
|
|
UnityEngine.Debug.Log(platform);
|
|
|
|
|
string response = "";
|
|
|
|
|
UnityEngine.Debug.Log(Application.persistentDataPath);
|
|
|
|
|
//Load Trial data from server
|
|
|
|
|
using (WebClient client = new WebClient())
|
|
|
|
|
{
|
|
|
|
|
string endpoint = "http://<URL OF SERVER INSTANCE>" + platform;
|
|
|
|
|
string endpoint = "http://<SERVER INSTANCE URL>/" + platform;
|
|
|
|
|
response = client.DownloadString(endpoint);
|
|
|
|
|
UnityEngine.Debug.Log("Received Response: " + response);
|
|
|
|
|
}
|
|
|
|
@ -172,7 +173,16 @@ public class ExperimentController : MonoBehaviour {
|
|
|
|
|
else if(nextDot.name.Contains("Long")){
|
|
|
|
|
sample.Distance = 1500;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
if (nextDot.name.Contains("Up")){
|
|
|
|
|
sample.Angle = 90;
|
|
|
|
|
}
|
|
|
|
|
else if (nextDot.name.Contains("Right"))
|
|
|
|
|
{
|
|
|
|
|
sample.Angle = 0;
|
|
|
|
|
}else if (nextDot.name.Contains("Left"))
|
|
|
|
|
{
|
|
|
|
|
sample.Angle = 180;
|
|
|
|
|
}
|
|
|
|
|
sample.Time = time;
|
|
|
|
|
sample.Direction = direction;
|
|
|
|
|
sample.DotName = nextDot.name;
|
|
|
|
|