add LiveSheet Support

This commit is contained in:
1605296300@qq.com
2022-09-03 13:55:00 +08:00
parent aebef9b584
commit 8eafe19956
17 changed files with 2056 additions and 1608 deletions
+24
View File
@@ -29,6 +29,7 @@ public class UmaViewerUI : MonoBehaviour,FaceLoadCallBack
public ScrollRect SceneList;
public ScrollRect FacialList;
public ScrollRect LiveList;
//settings
public TMPro.TMP_InputField SSWidth, SSHeight;
@@ -38,6 +39,7 @@ public class UmaViewerUI : MonoBehaviour,FaceLoadCallBack
public GameObject UmaContainerPrefab;
public GameObject UmaContainerSliderPrefab;
public GameObject UmaContainerAssetsPrefab;
public GameObject UmaContainerNoTMPPrefab;
private int LoadedAssetCount = 0;
[SerializeField] private RectTransform LoadedAssetsPanel;
@@ -144,6 +146,22 @@ public class UmaViewerUI : MonoBehaviour,FaceLoadCallBack
}
}
public void LoadLivePanels()
{
foreach (var live in Main.Lives.OrderBy(c => c.MusicId))
{
var liveInstance = live;
var container = Instantiate(UmaContainerNoTMPPrefab, LiveList.content).GetComponent<UmaUIContainer>();
container.GetComponentInChildren<Text>().text = " "+ live.MusicId + " " + live.songName;
var imageInstance1 = container.GetComponent<Image>();
container.Button.onClick.AddListener(() => {
HighlightChildImage(LiveList.content, imageInstance1);
Builder.LoadLive(live.MusicId);
});
}
}
public void LoadMiniModelPanels()
{
var container = Instantiate(UmaContainerPrefab, MiniAnimationSetList.content).GetComponent<UmaUIContainer>();
@@ -369,4 +387,10 @@ public class UmaViewerUI : MonoBehaviour,FaceLoadCallBack
}
}
public void ClearCache()
{
PlayerPrefs.DeleteAll();
Application.Quit();
}
}