Unity文件操作——调用减压文件解压
来源:互联网 发布:网络贷款还不起怎么办 编辑:程序博客网 时间:2024/04/30 06:49
注:移动端解压文件请到如下链接——http://blog.csdn.net/aiyan1111111/article/details/52769123
使用Unity调用系统解压工具解压文件:</pre></h2><p><span style="font-size:18px;"><strong>具体方法如下——直接上代码:</strong></span></p><p><span style="font-size:18px;"><strong></strong></span></p><p><span style="font-size:18px;"><strong></strong></span><pre name="code" class="html"><span style="font-size:14px;">
using UnityEngine;using System;using System.IO;using System.Diagnostics;public class Test : MonoBehaviour{ //7z程序的程序目录 private string _7zExeUrl ; void Start() { _7zExeUrl = Application.dataPath + "/StreamingAssets/7z.exe"; DecompressFileToDirectory(Application.dataPath + "/StreamingAssets/test.zip", Application.dataPath + "/StreamingAssets/"); } public void DecompressFileToDirectory(string inFileath, string outFilePath) { try { Process process = new Process(); string info = " x " + inFileath + " -o" + outFilePath + " -r "; ProcessStartInfo startInfo = new ProcessStartInfo(_7zExeUrl, info); process.StartInfo = startInfo; //隐藏DOS窗口 process.StartInfo.WindowStyle = ProcessWindowStyle.Hidden; process.Start(); process.WaitForExit(); process.Close(); } catch (Exception e) { UnityEngine.Debug.Log(e); } }}</span>
0 0
- Unity文件操作——调用减压文件解压
- Unity文件操作——File调用内置Exe程序
- unity解压文件变态提速
- 对文件压缩解压操作
- 文件上传、压缩解压 操作
- unity文件操作路径
- Unity文件操作路径
- unity操作ini文件
- linux系统调用——文件操作
- Unity Android调用.so文件
- 强悍的 Linux —— 文件解压与解压
- C调用Zlib库解压文件示例
- C++调用WinRAR压缩解压文件
- Unity3D调用7z解压文件
- Qt调用zlib压缩解压文件
- Unity 代码操作XML文件
- Unity--System.IO文件操作
- 解压文件
- OS X系统修改文件名时提示不能修改
- spark机器学习笔记:(三)用Spark Python构建推荐系统
- Android 混淆打包apk点击Home键重启App的问题
- django中的一个数据库错误 django.db.utils.InternalError: 1366
- emulator: ERROR: x86 emulation currently requires hardware acceleration!Please ensure Intel HAXM is
- Unity文件操作——调用减压文件解压
- TimesTen 数据库复制学习:9. 更改Active Standby Pair
- JSP实现验证码(利用tooltip进行消息提示)
- 复数四则运算--类模板实现
- java中各种术语
- HDU 5038 Grade
- os.time 和 os.date
- 【git】 安装与使用
- day_03文件操作模式