fix creating folders

This commit is contained in:
in0finite 2022-01-16 22:54:57 +01:00
parent 8d936b3499
commit 4c03c5f33f

View file

@ -233,17 +233,17 @@ namespace SanAndreasUnity.Editor
string[] folders = new string[] string[] folders = new string[]
{ {
"Models", ModelsPath,
"Materials", MaterialsPath,
"Textures", TexturesPath,
"Prefabs", PrefabsPath,
"CollisionModels", CollisionModelsPath,
}; };
foreach (string folder in folders) foreach (string folder in folders)
{ {
if (!AssetDatabase.IsValidFolder(Path.Combine(m_selectedFolder, folder))) if (!Directory.Exists(folder))
AssetDatabase.CreateFolder(m_selectedFolder, folder); Directory.CreateDirectory(folder);
} }
} }