zxl
/
CTT
forked from Cal/CTT
1
0
Fork 0
CTT/Unity/Assets/Editor/Assistent/Misc/AssistentHelper.cs

29 lines
501 B
C#
Raw Normal View History

2021-04-08 20:09:59 +08:00
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
using System.IO;
namespace ET
{
public static class AssistentHelper
{
public static void CheckDirectory(string dir)
{
if (Directory.Exists(dir) == false)
{
Directory.CreateDirectory(dir);
}
}
public static void CheckFile(string path)
{
if (File.Exists(path) == false)
{
FileStream fs = File.Create(path);
fs.Close();
AssetDatabase.Refresh();
}
}
}
}