Add basic arguments validation
This commit is contained in:
@@ -15,7 +15,6 @@ using System.Drawing.Imaging;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using OpenRA.FileFormats;
|
||||
using OpenRA.Mods.Common.SpriteLoaders;
|
||||
|
||||
@@ -25,6 +24,11 @@ namespace OpenRA.Mods.Common.UtilityCommands
|
||||
{
|
||||
public string Name { get { return "--shp"; } }
|
||||
|
||||
public bool ValidateArguments(string[] args)
|
||||
{
|
||||
return args.Length >= 2;
|
||||
}
|
||||
|
||||
[Desc("PNGFILE [PNGFILE ...]", "Combine a list of PNG images into a SHP")]
|
||||
public void Run(ModData modData, string[] args)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user