AssemblyCSharp.LoaderUtil.LoadTextFromFile C# (CSharp) Метод

LoadTextFromFile() публичный статический Метод

public static LoadTextFromFile ( string path ) : string
path string
Результат string
        public static string LoadTextFromFile(string path)
        {
            if (path.StartsWith(ResourcePaths.ROOT_RESOURCES))
            {
            var pattern = @"(Assets/Resources/)([^.]*)(\..*)";
            path = Regex.Replace(path, pattern, "$2");
            return LoadTextFromResource(path);
            }
            else if (File.Exists(path))
            {
            return File.ReadAllText(path);
            }

            PSDebug.Log("error loading text file from path: {0}", path);
            return null;
        }