public static string GetDeviceID()
{
#if UNITY_WEBGL
string uuid = "undefined";
//UnityEngine.Debug.Log("Duane, entering into the while loop");
string webGLGuidPath = "external_udid";
//UnityEngine.Debug.Log("Reading from " + webGLGuidPath);
if (System.IO.File.Exists(webGLGuidPath))
{
uuid = System.IO.File.ReadAllText(webGLGuidPath);
// UnityEngine.Debug.Log("uuid is : " + uuid);
}
else
{
UnityEngine.Debug.Log("Still waiting for a identifier from the webserver.");
}
return uuid.TrimEnd( '\r', '\n' );
#endif
return SystemInfo.deviceUniqueIdentifier;
}