This commit is contained in:
Perfare
2018-11-24 23:30:04 +08:00
parent 0a5b866a03
commit ec9184ba93
2 changed files with 19 additions and 7 deletions

View File

@ -466,7 +466,7 @@ namespace AssetStudioGUI
});
}
public static void ExportSplitObjects(string savePath, TreeNodeCollection nodes)
public static void ExportSplitObjects(string savePath, TreeNodeCollection nodes, bool openAfterExport)
{
ThreadPool.QueueUserWorkItem(state =>
{
@ -519,6 +519,10 @@ namespace AssetStudioGUI
Logger.Info($"Finished exporting {filename}.fbx");
}
}
if (openAfterExport)
{
Process.Start(savePath);
}
Logger.Info("Finished");
});
}
@ -532,7 +536,7 @@ namespace AssetStudioGUI
}
}
public static void ExportAnimatorWithAnimationClip(AssetItem animator, List<AssetItem> animationList, string exportPath)
public static void ExportAnimatorWithAnimationClip(AssetItem animator, List<AssetItem> animationList, string exportPath, bool openAfterExport)
{
ThreadPool.QueueUserWorkItem(state =>
{
@ -540,6 +544,10 @@ namespace AssetStudioGUI
try
{
ExportAnimator(animator, exportPath, animationList);
if (openAfterExport)
{
Process.Start(exportPath);
}
Logger.Info($"Finished exporting {animator.Text}");
}
catch (Exception ex)
@ -550,7 +558,7 @@ namespace AssetStudioGUI
});
}
public static void ExportObjectsWithAnimationClip(string exportPath, TreeNodeCollection nodes, List<AssetItem> animationList = null)
public static void ExportObjectsWithAnimationClip(string exportPath, TreeNodeCollection nodes, bool openAfterExport, List<AssetItem> animationList = null)
{
ThreadPool.QueueUserWorkItem(state =>
{
@ -577,6 +585,10 @@ namespace AssetStudioGUI
Progress.Report(++i, count);
}
if (openAfterExport)
{
Process.Start(exportPath);
}
}
else
{