diff --git a/README b/README new file mode 100644 index 0000000..e69de29 diff --git a/UsmToolkit/Program.cs b/UsmToolkit/Program.cs index 61104ea..c7608c4 100644 --- a/UsmToolkit/Program.cs +++ b/UsmToolkit/Program.cs @@ -60,7 +60,10 @@ namespace UsmToolkit public string InputPath { get; set; } [Option(CommandOptionType.NoValue, Description = "Join files after extraction.", ShortName = "j", LongName = "join")] - public bool JoinOutput { get; set; } + public bool Join { get; set; } + + [Option(CommandOptionType.SingleValue, Description = "Specify output directory.", ShortName = "o", LongName = "output-dir")] + public string OutputDir { get; set; } [Option(CommandOptionType.NoValue, Description = "Remove temporary m2v and audio after joining.", ShortName = "c", LongName = "clean")] public bool CleanTempFiles { get; set; } @@ -95,7 +98,7 @@ namespace UsmToolkit SplitAudioStreams = false }); - if (JoinOutput) + if (Join) { JoinOutputFile(usmStream); } @@ -152,7 +155,7 @@ namespace UsmToolkit if (usmStream.HasAudio) sb.Append($"{conf.AudioParameter} "); - sb.Append($"{pureFileName}.{conf.OutputFormat}"); + sb.Append($"\"{Path.Combine(OutputDir ?? string.Empty, $"{pureFileName}.{conf.OutputFormat}")}\""); return sb.ToString(); } diff --git a/UsmToolkit/Properties/launchSettings.json b/UsmToolkit/Properties/launchSettings.json index 348f2c0..b2b79e5 100644 --- a/UsmToolkit/Properties/launchSettings.json +++ b/UsmToolkit/Properties/launchSettings.json @@ -2,7 +2,7 @@ "profiles": { "UsmToolkit": { "commandName": "Project", - "commandLineArgs": "extract \"F:\\CUSA05787\\tresgame\\content\\crimovie\\rebellis02\\en\\cs_dw009_mv.usm\" --join" + "commandLineArgs": "" } } } \ No newline at end of file