Add option for GUI and CLI

This commit is contained in:
fricyo
2026-07-01 01:59:12 +00:00
parent b1d4b97ae9
commit 1141418ec2
9 changed files with 313 additions and 256 deletions
+2 -1
View File
@@ -76,9 +76,10 @@ namespace AssetStudioCLI
debugLog = "";
var type = CLIOptions.o_imageFormat.Value;
var alphaMask = SpriteMaskMode.On;
var spriteWithCanvas = CLIOptions.f_spriteWithCanvas.Value;
if (!TryExportFile(exportPath, item, "." + type.ToString().ToLower(), out var exportFullPath))
return false;
var image = ((Sprite)item.Asset).GetImage(alphaMask);
var image = ((Sprite)item.Asset).GetImage(alphaMask, spriteWithCanvas: spriteWithCanvas);
if (image != null)
{
using (image)