整合包

gameplay bundle has been imported together
This commit is contained in:
FloatGaming
2025-08-09 18:29:32 +08:00
parent e7962bf492
commit 1d818fa4eb
1654 changed files with 431813 additions and 103 deletions
+19
View File
@@ -0,0 +1,19 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
[RequireComponent(typeof(Toggle))]
public class UI_Toggle : MonoBehaviour
{
Toggle toggle;
void Awake()
{
TryGetComponent(out toggle);
Active(toggle.isOn);
toggle.onValueChanged.AddListener(Active);
}
void Active(bool isOn)
{
toggle.graphic.gameObject.SetActive(isOn);
}
}