public static string ReadTextFileFromResources(string path, ZipDelegate zip=null){
string result = null;
if (Application.isPlaying) {
NSUtils.Assert (path.EndsWith (".txt"), "FileUtils: Text file in Resources folder must be '*.txt' format!");
string ext = Path.GetExtension(path);
path = path.Replace (ext, "");
TextAsset txt = Resources.Load<TextAsset> (path);
NSUtils.Assert (txt!=null, "No file found at {0}", path);
result = txt.text;
}else if (File.Exists (path)) {
// result = System.IO.File.ReadAllText(path);
result = ReadStringFromPath(path);
}
if (zip != null)
result = zip.unZip (result);
return result;
}