Example #1
0
        public static byte[] ReadAllBytes(string path)
        {
#if UNITY_ANDROID && !UNITY_EDITOR
            if (InApk(path))
                return AndroidFileUtil.ReadAllBytes(path);
#endif
            return File.ReadAllBytes(path);
        }
Example #2
0
        public static bool Exists(string path)
        {
#if UNITY_ANDROID && !UNITY_EDITOR
            if (InApk(path))
                return AndroidFileUtil.Exists(path);
#endif
            return File.Exists(path);
        }
Example #3
0
        public static string ReadAllText(string path, Encoding encoding)
        {
#if UNITY_ANDROID && !UNITY_EDITOR
            if (InApk(path))
                return AndroidFileUtil.ReadAllText(path, encoding);
#endif
            return File.ReadAllText(path, encoding);
        }