From da5f232dcc34e01ebb4a267cd1dbd4211915668c Mon Sep 17 00:00:00 2001 From: Razmoth <32140579+Razmoth@users.noreply.github.com> Date: Sun, 17 Sep 2023 01:47:40 +0400 Subject: [PATCH] - [CLI] Create output folder if not exist --- AssetStudioCLI/Program.cs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/AssetStudioCLI/Program.cs b/AssetStudioCLI/Program.cs index 50850f4..97993fb 100644 --- a/AssetStudioCLI/Program.cs +++ b/AssetStudioCLI/Program.cs @@ -50,6 +50,7 @@ namespace AssetStudioCLI assetsManager.Silent = o.Silent; assetsManager.Game = game; ModelOnly = o.Model; + o.Output.Create(); if (o.Key != default) { @@ -86,10 +87,6 @@ namespace AssetStudioCLI { throw new Exception("Unable to build AssetMap with input_path as a file !!"); } - if (!o.Output.Exists) - { - o.Output.Create(); - } var resetEvent = new ManualResetEvent(false); AssetsHelper.BuildAssetMap(files, o.MapName, game, o.Output.FullName, o.MapType, resetEvent, o.TypeFilter, o.NameFilter, o.ContainerFilter); resetEvent.WaitOne();