public IEnumerator Load <R>(DataLoader.IResultReceiver loader, string path) where R : Google.Protobuf.IMessage <R> { //TODO: update csv if necessary (with assetbundle or something) CSVSource s; try { #if UNITY_ANDROID && !UNITY_EDITOR WWW www = new WWW(path); yield return(www); if (!string.IsNullOrEmpty(www.error)) { throw new System.Exception(www.error); } s = new CSVSource(new StringReader(www.text)); #else s = new CSVSource(new StreamReader(TrimBOM(path))); #endif } catch (System.Exception e) { loader.Error = e; yield break; } s.Read(); s.ReadHeader(); Source = s; yield break; }