gif and eyebrow bug fix

This commit is contained in:
CroakFang
2023-11-01 01:36:24 +08:00
parent e850c2f72d
commit ec0e9b0e61
3 changed files with 37 additions and 29 deletions
+3 -2
View File
@@ -39,9 +39,10 @@ namespace uGIF
while(bytes == null) yield return new WaitForEndOfFrame();
string fileName = Application.dataPath + "/../Screenshots/" + string.Format("UmaViewer_{0}", DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss-fff"));
Directory.CreateDirectory(Application.dataPath + "/../Screenshots");
File.WriteAllBytes(fileName + ".gif", bytes);
var fullpath = $"{fileName}.gif";
File.WriteAllBytes(fullpath, bytes);
bytes = null;
Debug.Log("Gif saved!");
UmaViewerUI.Instance.ShowMessage($"GIF saved: {fullpath}", UIMessageType.Success);
Frames.Clear();
stop = false;
UmaViewerUI.Instance.GifButton.GetComponentInChildren<TMPro.TextMeshProUGUI>().text = "Record GIF";