- [GUI] fix bug when building AssetMap with stripped version.

This commit is contained in:
Razmoth
2023-09-17 00:07:12 +04:00
parent 5e6ddc31c9
commit 7e26194fff
2 changed files with 8 additions and 0 deletions

View File

@@ -32,6 +32,11 @@ namespace AssetStudio
public string[] Dependencies { get; set; }
}
public static void SetUnityVersion(string version)
{
assetsManager.SpecifyUnityVersion = version;
}
public static string[] GetMaps()
{
Directory.CreateDirectory(MapName);
@@ -46,6 +51,7 @@ namespace AssetStudio
CABMap.Clear();
Offsets.Clear();
BaseFolder = string.Empty;
assetsManager.SpecifyUnityVersion = string.Empty;
tokenSource.Dispose();
tokenSource = new CancellationTokenSource();

View File

@@ -2280,6 +2280,7 @@ namespace AssetStudioGUI
name = input;
}
var version = specifyUnityVersion.Text;
var openFolderDialog = new OpenFolderDialog();
openFolderDialog.Title = $"Select Game Folder";
if (openFolderDialog.ShowDialog(this) == DialogResult.OK)
@@ -2303,6 +2304,7 @@ namespace AssetStudioGUI
}
}
saveDirectoryBackup = saveFolderDialog.Folder;
AssetsHelper.SetUnityVersion(version);
await Task.Run(() => AssetsHelper.BuildAssetMap(files, name, Studio.Game, saveFolderDialog.Folder, exportListType));
}
}