UI update 02

This commit is contained in:
FloatGaming
2026-06-30 21:21:30 +08:00
parent b2a1e307a4
commit f62f643cfc
1666 changed files with 211081 additions and 22799 deletions
+47
View File
@@ -0,0 +1,47 @@
using UnityEngine;
#if INPUT_SYSTEM_ENABLED
using Input = XCharts.Runtime.InputHelper;
#endif
using XCharts.Runtime;
namespace XCharts.Example
{
[DisallowMultipleComponent]
[ExecuteInEditMode]
public class Example_Test : MonoBehaviour
{
BaseChart chart;
void Awake()
{
chart = gameObject.GetComponent<BaseChart>();
}
void Update()
{
if (Input.GetKeyDown(KeyCode.Space))
{
AddData();
}
else if (Input.GetKeyDown(KeyCode.R))
{
chart.AnimationReset();
chart.AnimationFadeIn();
}
else if (Input.GetKeyDown(KeyCode.U))
{
chart.UpdateData(0, 2, 99);
}
else if (Input.GetKeyDown(KeyCode.C))
{
chart.UpdateData(0, 2, 22);
}
}
void AddData()
{
chart.AnimationReset();
chart.AnimationFadeOut();
}
}
}